-
-
Notifications
You must be signed in to change notification settings - Fork 7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug Report] Could not find a declaration file for module 'vuetify/lib' #5944
Comments
@KaelWD Thank you for the link. More specifically, this comment helped me out to properly update my tsconfig.json: "compilerOptions": {
"types": ["...", "vuetify"], |
This is not a good solution for two reasons:
The recommended solution is to have the declaration files output alongside the built JavaScript files. Can this please be done? Edit: Correction to point |
Hello guys, any news on this ?? |
I had similar errors on a fresh install. Once I did this, it worked. Go in src/main.ts and paste the following content right after the imports https://medium.com/@attiewilly/how-i-married-vuetify-with-typescript-d6441dedd16 |
In our projects, we use The generated file
remove the it will solve the issue. 🥂 if you are looking for a-la-carte installation please read: this |
@ferrywlto thanks! I've just used everything brand new including Vuetify 2.0.10, and stumbled upon this issue. |
I solved it by deleting the instance and imports of a component that had been deleted. |
Adding this module declaration to a declare module 'vuetify/lib' {
import 'vuetify/types/lib'
} |
This is really annoying, none of the above solutions works for me. If i do
the error disappears but styles are missing fonts.
did not work either, SOLUTION: BUT this did the trick (in my tsconfig.json) , add "vuetify" to types: "types": [ |
@devpixde "vuetify" should be in the types anyway, but that is not what helped me out. I've changed the import statement to Btw, the problem has been confirmed on official discord #bugs channel on 09/09/2019, but I've no idea if that yielded anything further. |
This is added in the FAQ section of the docs. |
Can this not be fixed properly instead of just documenting a workaround? |
This is still an issue with a brand new project created with vue cli 4 and then adding vuetify via |
If you use {
"compilerOptions": {
"typeRoots": [
"./node_modules/vuetify/types"
]
}
} It seems it would be ideal to have an |
This comment has been minimized.
This comment has been minimized.
I think this could also be solved with package exports, but this has not yet been implemented in TypeScript. |
I was having trouble. |
@vernaschwartz We kindly ask users to not comment on closed/resolved issues. If you believe that this issue has not been correctly resolved, please create a new issue showing the regression. If you have any additional questions, please reach out to us in our Discord community. |
Versions and Environment
Vuetify: 1.3.15
Vue: 2.5.17
Browsers: Google Chrome
OS: Windows 10
Steps to reproduce
Hi guys, I follow the Vue-CLI 3 guide and when I try to compile the source code the terminal show me a Typescript error.
Expected Behavior
The Typescript code should compile.
Actual Behavior
Reproduction Link
https://codepen.io/MatiasOlivera/pen/JwbQqy
Other comments
Typescript: 3.2.2
The text was updated successfully, but these errors were encountered: