-
Notifications
You must be signed in to change notification settings - Fork 87
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
[Vue warn]: Invalid Component definition #83
Comments
Same here 😢 |
What's the line where the error occurs and what gets imported? |
The problem for me was my webpack loader configuration. I'm using Storybook and the default webpack config includes an image loader that was catching my |
It did not work for me after copying exactly the Vue Cli code from https://vue-svg-loader.js.org/faq.html#how-to-use-both-inline-and-external-svgs, As I have both inline svg and external. I was actually placing the inline keyword at the wrong place, it has to be that and not the opposite: js import Wave from '@/assets/file.svg?inline' css background: url('~@/assets/another-file.svg') bottom; |
If anyone ends up here trying to use this with Rails webpacker, you have to modify the webpacker-provided // environment.js
const fileLoader = environment.loaders.get('file')
fileLoader.test = new RegExp(fileLoader.test.source.replace(/\|?\.svg/, ''), 'i') |
@bbugh you beautiful beautiful boy you just saved me an afternoon @rafaelmonroy thank you! |
Good afternoon, I try to use the plugin, but I get an error Invalid Component definition. What could be the problem?
I do everything as described. I use vue cli 3. I changed the loader for svg in the file vue.config.js but this does not help ...
This is what the vue inspect command gives me https://yadi.sk/d/-frdPIPX5dSamA I don’t see there anything else that can interfere with the processing
The text was updated successfully, but these errors were encountered: