vue-spinner-component
vue-spinner-component copied to clipboard
Cannot load in my project due to loader issue
ERROR in ./node_modules/vue-spinner-component/src/Spinner.vue 1:0 Module parse failed: Unexpected token (1:0) You may need an appropriate loader to handle this file type.
Is this able to use or only works standalone?
Just ran into this myself. It's because Spinner.vue
uses <style lang="scss">...</style>
, so if you don't have node-sass
and sass-loader
, the Vue template compiler will fail.
Not only that, but Spinner.vue
's style is perfectly valid css, which means that the lang="scss"
could be removed without doing anything more.
For a quick fix, just copy Spinner.vue
into your project (to import it locally) and remove the lang="scss"
attribute from the <style/>
tag.