-
How to make exported |
Beta Was this translation helpful? Give feedback.
Answered by
mesqueeb
Aug 20, 2022
Replies: 1 comment
-
If your
-- If this gives you issues with your project setup, you can set up a separate eg. {
"compilerOptions": {
// ...
"baseUrl": ".",
"outDir": "dist"
},
"include": ["./src/**/*.vue"]
} Then in your script you make sure that
"generate:types": "vue-tsc --declaration --emitDeclarationOnly --project tsconfig.declaration.json", |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
mesqueeb
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If your
tsconfig.json
"include" is only pointing at stuff inside yoursrc
folder, it will not be included when building the type declarations."include": ["./**/*.vue"]
this will includesrc
folder insidedist
→dist/src
"include": ["./src/**/*.vue"]
this wont includesrc
folder, it will emit directly intodist
--
If this gives you issues with your project setup, you can set up a separate
tsconfig.json
for emitting the type declarations.eg.
tsconfig.declaration.json
Then in your script you make sure that
tsconfig.declaration.json
is used instead.package.json
scripts:"…