Skip to content

feat(cozy-tsconfig): Remove declarationDir#2986

Merged
JF-Cozy merged 1 commit intomasterfrom
chore/ts
Apr 9, 2026
Merged

feat(cozy-tsconfig): Remove declarationDir#2986
JF-Cozy merged 1 commit intomasterfrom
chore/ts

Conversation

@JF-Cozy
Copy link
Copy Markdown
Contributor

@JF-Cozy JF-Cozy commented Apr 9, 2026

Summary by CodeRabbit

  • Chores
    • Updated TypeScript configuration to allow individual projects to define their own declaration directory settings instead of enforcing a global override.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 9, 2026

Warning

Rate limit exceeded

@JF-Cozy has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 14 minutes and 6 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 14 minutes and 6 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 1174be58-99ec-4fbe-8e4a-b2b7bf3e09e3

📥 Commits

Reviewing files that changed from the base of the PR and between 60860cd and f61ad75.

📒 Files selected for processing (1)
  • packages/cozy-tsconfig/tsconfig.json

Walkthrough

The tsconfig.json file in the cozy-tsconfig package was modified to remove the explicit declarationDir compiler option setting. Previously configured to output declaration files to "dist", this setting has been commented out. This change allows TypeScript to determine the declaration file output location based on the extending project's configuration rather than enforcing the base configuration's setting.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title directly and specifically describes the main change: removing the declarationDir configuration from the TypeScript config file.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/ts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/cozy-tsconfig/tsconfig.json`:
- Around line 15-17: Update the guidance comment about "declarationDir" to
explicitly state that consumers extending this base must define "declarationDir"
in their own tsconfig (and preferably "outDir" as well) because TypeScript
resolves relative paths from the base config location; reference the keys
"declarationDir" and "outDir" and note that packages like
packages/cozy-harvest-lib/tsconfig.json that extend the base without those
settings will inherit "outDir": "dist" from the base and may end up with outputs
written relative to the base package rather than the consumer project root, so
advise consumers to set both keys in their project tsconfig.json.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 35dcb68b-f52a-43fc-b848-a5e9feabe429

📥 Commits

Reviewing files that changed from the base of the PR and between da3d143 and 60860cd.

📒 Files selected for processing (1)
  • packages/cozy-tsconfig/tsconfig.json

BREAKING CHANGE: You must define `declarationDir` and `outDir` in  `compilerOptions` manually
@JF-Cozy JF-Cozy merged commit 84c7ffc into master Apr 9, 2026
3 checks passed
@JF-Cozy JF-Cozy deleted the chore/ts branch April 9, 2026 12:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant