Closed AlanLes closed 3 months ago
I am seeing this too. skipLibCheck
is true and node_modules
is in the excludes array, but I am still seeing errors related to node_modules.
> npx vue-tsc --project tsconfig.gen-dts.json --noEmit
node_modules/vue-slider-component/lib/utils/control.ts:554:22 - error TS6133: 'pos' is declared but its value is never read.
554 dotsPos.forEach((pos, i) => {
~~~
Found 1 error in node_modules/vue-slider-component/lib/utils/control.ts:554
This has nothing to do with vue-tsc, because this is a typescript limitation. If you import ts files from node_modules, it will be checked by typescript, no matter if skipLibCheck
is set to true or not. You have to import transpiled javascript files, not ts files.
See the typescript issue: https://github.com/microsoft/TypeScript/issues/40426
Yeeep, but I have those for the .vue
files (which are obviously not .ts
files), so what in this case?
I'm not sure if we can avoid this behavior: https://github.com/vuejs/language-tools/blob/master/packages/vue-tsc/bin/vue-tsc.js#L15-L17
Volar needs to patch tsc to include .vue
files so they can get typechecked, which leads to this error
I have no direct imports from the node_modules
but still have that same issue in turbo monorepo.
Please check if this issue has been resolved in version 2.x. If not, feel free to create a new one.
Hello, after updating
vue-tsc
to1.8.8
in one of the projects, I'm having problems with it throwing an error from an external library. When the project runs with vite, thevue-tsc
throws an error from the external open-source component-library. This library is based on a differentvue-tsc
version, but I think it shouldn't be an issue (it's an external library after all), should it? I think theskipLibCheck
flag in thetsconfig.json
should do the job, but for some reason it doesn't.The tsconfig in the project is the following: