After creating a vue3 project and installing the Vite framework, an error message appears when opening the project in vscode.

Error reporting

Version: vite4
Insert image description here
An error message appears after opening the newly installed vite project:

The following error appears in the App.vue file:
Insert image description here
The following error appears in the main.ts file:
Insert image description here
The following error appears in the tsconfig.app.json file: The following error
Insert image description here
appears in tsconfig.node.json :
Insert image description here
The following error appears in vite.config.ts: The error
Insert image description here
appears when the mouse is moved to the error location hint:

Insert image description here

Solution: Check the vscode version and update to the new version

Find the "Help" toolbar of vscode, select "Check for Updates", and update to the new version

Insert image description here
After updating vscode to a new version, and then opening the project just now, there will be no error.

Guess you like

Origin blog.csdn.net/qq_39111074/article/details/132734134