Skip to content

chore: keep single root tsconfig.json to align pnpm typecheck and vscode typescript#10010

Draft
hi-ogawa wants to merge 4 commits intovitest-dev:mainfrom
hi-ogawa:tsconfig-vscode-consistency
Draft

chore: keep single root tsconfig.json to align pnpm typecheck and vscode typescript#10010
hi-ogawa wants to merge 4 commits intovitest-dev:mainfrom
hi-ogawa:tsconfig-vscode-consistency

Conversation

@hi-ogawa
Copy link
Copy Markdown
Collaborator

@hi-ogawa hi-ogawa commented Mar 28, 2026

Description

Vscode picks up nearest tsconfig.json and it causes a discrepancy between pnpm typecheck failure and what shows up as red squiggles on vscode due to packages/*/tsconfig.json. This PR renames root tsconfig.check.json to tsconfig.json and rename all per-package tsconfig.json to tsconfig.build.json, so that Vscode always uses root tsconfig.json as a source of truth.

This can technically hide the real typing issue, but per-package typecheck wasn't verified consistently (and some are currently broken), so personally ensuring just pnpm typecheck is a good trade off and benefits enough from typescript. At times, pnpm typecheck fails while vscode shows no red squiggles and that's hard to understand.

Please don't delete this checklist! Before submitting the PR, please make sure you do the following:

  • It's really useful if your PR references an issue where it is discussed ahead of time. If the feature is substantial or introduces breaking changes without a discussion, PR might be closed.
  • Ideally, include a test that fails without this PR but passes with it.
  • Please, don't make changes to pnpm-lock.yaml unless you introduce a new test example.
  • Please check Allow edits by maintainers to make review process faster. Note that this option is not available for repositories that are owned by Github organizations.

Tests

  • Run the tests with pnpm test:ci.

Documentation

  • If you introduce new functionality, document it. You can run documentation with pnpm run docs command.

Changesets

  • Changes in changelog are generated from PR name. Please, make sure that it explains your changes in an understandable manner. Please, prefix changeset messages with feat:, fix:, perf:, docs:, or chore:.

hi-ogawa and others added 4 commits March 28, 2026 18:18
…nsistent VSCode experience

Make VSCode use the root tsconfig.json (previously tsconfig.check.json) for
all files, so editor type-checking matches `pnpm typecheck` exactly. Per-package
tsconfigs are kept as tsconfig.build.json for build tooling.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Root `pnpm typecheck` covers the full monorepo. Per-package scripts
were never run in CI and some were already broken due to lib mismatches
when following path aliases into other packages.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@netlify
Copy link
Copy Markdown

netlify bot commented Mar 28, 2026

Deploy Preview for vitest-dev ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit ac06ba5
🔍 Latest deploy log https://app.netlify.com/projects/vitest-dev/deploys/69c7a0a0963a4b00098372de
😎 Deploy Preview https://deploy-preview-10010--vitest-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@hi-ogawa
Copy link
Copy Markdown
Collaborator Author

Well, I guess this went too far. Practically, the types get extended only for package/expect and packages/runner, so we could limit to that.

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