Closed fabiog27 closed 2 months ago
Hey :) I'm unable to reproduce this error 🤔
Can you make sure you restart your TS server on vscode to see if you stil encounter it?
This issue has been automatically marked as stale because more information has not been provided within 7 days. It will be closed in 21 days if no information is provided. If information has been provided, please reply to keep it active. Thanks for being a part of the Nx community! 🙏
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.
Current Behavior
In a monorepository with @nx/vue, opening the file
apps/app-name/src/main.ts
, there is a TS2307 error on the import of App.vue.Expected Behavior
The import should be recognized correctly.
GitHub Repo
https://github.com/fabiog27/nx-dev-vue-ts-error
Steps to Reproduce
npm install
apps/demo/src/main.ts
Nx Report
Failure Logs
No response
Package Manager Version
No response
Operating System
Additional Information
I think it has to do with the language server that is picked for the file. In a standalone Vue project, it is the vue language server that is used even for the .ts files. In a monorepository, the TypeScript language server is used and the vue server is only used on .vue files.
On IntelliJ this can be forced with a .ws-context file in the workspace root with the following content:
However, this is cumbersome, and only works in IntelliJ.