language-tools: Component type is missing

I have just created a project with vite npm create vite@latest:

The type of the component is always any:

image

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Reactions: 10
  • Comments: 20 (5 by maintainers)

Most upvoted comments

FYI to solve this issue temporarily, install typescript@5.0 in your workspace and switch to it:

image image

The new version of vscode ships typescript@5.1 which breaks the type.

I updated my vscode to May 2023 version, same started happening for me, downgraded to April 2023 (version 1.78) version and it works again. ¯\_(ツ)_/¯

Because the latest VSCode ships typescript 5.1.3

Just found the reason: Link

Unresolved any is no longer “any” ¯_(ツ)_/¯