Skip to content

fix(tools): disable TypeScript in VS Code#20287

Closed
overlookmotel wants to merge 1 commit intomainfrom
om/03-12-fix_tools_disable_ts_in_vs_code
Closed

fix(tools): disable TypeScript in VS Code#20287
overlookmotel wants to merge 1 commit intomainfrom
om/03-12-fix_tools_disable_ts_in_vs_code

Conversation

@overlookmotel
Copy link
Member

@overlookmotel overlookmotel commented Mar 12, 2026

Disable TypeScript type-checking in VS Code in this repo. It's redundant because Oxc language server runs Oxlint, which performs type-checking.

It's also annoying having TS enabled because the versions of TypeScript used by VS Code and by Oxlint sometimes disagree (e.g. on whether RegExp.escape exists), which produces erroneous red squiggles in some cases.

This makes #20077 redundant.

Copy link
Member Author


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent changes, fast-track this PR to the front of the merge queue

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions github-actions bot added the C-bug Category - Bug label Mar 12, 2026
@overlookmotel overlookmotel marked this pull request as ready for review March 12, 2026 12:11
Copilot AI review requested due to automatic review settings March 12, 2026 12:11
@overlookmotel overlookmotel changed the title fix(tools): disable TS in VS Code fix(tools): disable TypeScript in VS Code Mar 12, 2026
@overlookmotel
Copy link
Member Author

@camc314 Do you think this is a cleaner solution than #20077? Or am I missing some unintended consequences?

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Disables VS Code’s built-in TypeScript diagnostics for this repository to avoid duplicate/incorrect editor error reporting, relying instead on the Oxc language server (Oxlint type-aware checking).

Changes:

  • Adds a VS Code workspace setting intended to turn off JS/TS validation diagnostics from VS Code/TypeScript.
  • Documents why TS validation is disabled (TS version mismatches vs Oxlint/tsgolint).

},
// Disable TypeScript's error checking — Oxlint handles this via the Oxc language server.
// VS Code's bundled TS version can disagree with Oxlint's newer TS support (via tsgolint).
"js/ts.validate.enabled": false,
Copy link

Copilot AI Mar 12, 2026

Choose a reason for hiding this comment

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

The setting key js/ts.validate.enabled doesn’t match VS Code’s built-in JS/TS validation settings, so this likely has no effect. To actually disable diagnostics from the TypeScript language service, use "typescript.validate.enable": false (and optionally "javascript.validate.enable": false if you also want JS files to stop showing TS-server validation errors).

Suggested change
"js/ts.validate.enabled": false,
"typescript.validate.enable": false,
"javascript.validate.enable": false,

Copilot uses AI. Check for mistakes.
Copy link
Member Author

Choose a reason for hiding this comment

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

The settings you suggest are out of date. js/ts.validate.enabled is the setting in current VS Code.

Copy link
Contributor

@camc314 camc314 left a comment

Choose a reason for hiding this comment

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

We don't run typecheck when linting inside the editor, as we rely on the language server for this, so it'll probably cause missing diagnostics

@overlookmotel
Copy link
Member Author

Oh dammit you're right!

@overlookmotel overlookmotel deleted the om/03-12-fix_tools_disable_ts_in_vs_code branch March 12, 2026 13:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C-bug Category - Bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants