sass-loader on webpack in Asp.Net Core

I need help in connecting the style loader scss-loader

i try include sass-loader in webpack.config.js for

vue-component:

@import '@/styles/mixin.scss';

webpack.config.js:

....
    {
    test: /\.scss$/,
    exclude: /(node_modules)/,
    use: [
      'style-loader',
      'css-loader',
      'sass-loader'
    ]
  },
....

but have all times error

Error: Module build failed (from ./node_modules/sass-loader/lib/loader.js):
undefined
^
  File to import not found or unreadable: src/styles/mixin.scss.

Any ideas how to cure this?

Upvotes: 0

Views: 347

Answers (1)

in vue component imports module have path 'src/name.scss' change it and loader works

Upvotes: 1

Related Questions