Skip to content

TS 7 language server: "Add missing properties" quick fix not offered #64689

Description

🔎 Search Terms

"add missing properties", "quick fix", "code action", "TS 7", "native language server"

🕗 Version & Regression Information

  • This changed between versions 6.0.3 and 7.0.2
  • This changed in commit or PR: unknown (likely the codefix hasn't been ported to the native language server)
  • This is the behavior in every version I tried, and I reviewed the FAQ for entries about quick fixes and the TS 7 native language server (none found)
  • Note: 6.0.3 was tested in the Playground, where "Add missing properties" is offered. The Playground has no TS 7 option, so TS 7.0.2 was tested in VS Code 1.140.0.

⏯ Playground Link

https://www.typescriptlang.org/play/?ts=6.0.3#code/C4TwDgpgBAKlC8UDeUCGAuKA7ArgWwCMIAnAbigMwGdhiBLLAcygF8AoAYwHssaphMcREhZA

💻 Code

type T = { a: number; b: string }
const t: T = {}

🙁 Actual behavior

Error: Type '{}' is missing the following properties from type 'T': a, b
"No quick fixes available" when TypeScript 7 Language Server is enabled

🙂 Expected behavior

Error: Type '{}' is missing the following properties from type 'T': a, b
Quick Fix "Add missing properties" is offered. After applying:

type T = { a: number; b: string }
const t: T = {
a: 0,
b: ""
}

Additional information about the issue

The playground link is for TypeScript 6.0.3 as there is no option to use Typescript 7.0 ("Nightly" is v6.0.0-dev.20260416)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions