Home

Issue: 295

Global SCSS loading

[issue link]

Hi !

I tried to add a global sass file in my project by doing:

// file: nuxt.config.js 
css: [
    'element-ui/lib/theme-default/index.css',
    { src: '~plugins/themes/portal.scss', lang: 'sass'}
  ],

but I’m getting the following error:

ERROR in ./~/css-loader!./~/vue-loader/lib/style-rewriter.js?id=data-v-76ea6e06!./~/sass-loader/lib/loader.js?indentedSyntax!./plugins/themes/portal.scss
Module build failed: 
html, .bold, .regular, body, h1, h2, h3, h4, h5, h6, input, li, p, textarea, div {
Invalid CSS after "...textarea, div {": expected "}", was "{"

Loading sass files from my vue components works fine.

Any idea how to fix that ?

This question is available on Nuxt.js community (#c247)