Hi,
I get alot of errors/notifications inside Visual Studio Code by TS.
Some examples:
- Open ApiService.ts
- Cannot find module 'vue' or its corresponding type declarations.ts(2307)
- Cannot find module 'axios' or its corresponding type declarations.ts(2307)
What causes this problem? Typescript version? How to solve it?
It works in the projects here, tested in version 8.20 metronic, vue3.
Create a file at:
src/shims-vue.d.ts
Code:
declare module '*.vue';
Hi,
Unfortunately, we were not able to reproduce this issue in the latest Metronic version. These imports don't throw any errors. It might be related to your Visual Studio Code used extension or configuration. Could you please specify which vue extensions are you using in your Visual Studio Code?
You might have an error with Visual Studio Code when using a Volar extension it might highlight some components, to fix this you can refer to the GitHub issue below.
https://github.com/johnsoncodehk/volar/discussions/592#discussioncomment-1763880
Regards,
Lauris Stepanovs,
Keenthemes Support Team