Using webpack to prepend variables for SCSS
问题 Webpack amateur here... I'm trying to incorporate a theme.scss file to customize the theme used by React Toolbox by following the directions specified here, namely: If you are using Webpack as module bundler, you are probably using sass-loader as well. What we want to do is to prepend to each SASS file compilation a bunch of variables to override and this can be done with the data option. For example: sassLoader: { data: '@import "' + path.resolve(__dirname, 'theme/_theme.scss') + '";' } In