Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const path = require('path');
- module.exports = {
- entry: './src/app.js',
- output: {
- filename: 'bundle.js',
- path: path.resolve(__dirname, 'dist')
- },
- module: {
- rules: [
- {
- test: /\.(scss)$/,
- use: [
- {
- // Adds CSS to the DOM by injecting a `<style>` tag
- loader: 'style-loader'
- },
- {
- // Interprets `@import` and `url()` like `import/require()` and will resolve them
- loader: 'css-loader'
- },
- {
- // Loader for webpack to process CSS with PostCSS
- loader: 'postcss-loader',
- options: {
- plugins: function () {
- return [
- require('autoprefixer')
- ];
- }
- }
- },
- {
- // Loads a SASS/SCSS file and compiles it to CSS
- loader: 'sass-loader'
- }
- ]
- }
- ]
- }
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement