1

I am trying to load scss style sheets for my application running on webpack and PostCSS.

Unfortunately, i get the following error

(Emitted value instead of an instance of Error) postcss-import: .../file.scss:2:1: Cannot find module 'compass' from '../scss'

I've already installed compass from npm.

This is my webpack setup :

{
        test: /\.s(a|c)ss$/,
        use: ['babel-loader', 'raw-loader','postcss-loader',
          { loader: 'sass-resources-loader',
            options: {
              resources: ['./styles/scss/file.scss','./styles/scss/anotherFile.scss']
            }
          }

And my PostCSS config

module.exports = {
  plugins: [
    require('postcss-easy-import')({prefix: '_'}), // keep this first
    require('autoprefixer')({ /* ...options */ }), // so imports are 
  ]
}

So any suggestion to help me ?

0 Answers0