Roots Discourse

Webpack handler for node_modules library scss fix

Hi all,

I had some trouble getting webpack to work with the aos library for animations, which uses an import statement to nab an scss file in its js code.

I have filed an issue and PR on github to cover this issue

Before I did this i got errors such as

 error  in ./node_modules/aos/src/sass/aos.scss

Module parse failed: Unexpected character '@' (1:0)
You may need an appropriate loader to handle this file type.

The following change to webpack.config.js worked , by adding node_modules in a bracket. So I have put that in the pull request in case this is helpful for the community.

    test: /\.scss$/,
    include: [config.paths.assets, /node_modules/],

I am not too familiar with webpack so perhaps this may not be helpful for everyone. But it worked for me so far!

Other than that everything has been going pretty well. Thanks!