css - How to run postcss and its plugins in bootstrap-loader? -


import new styles , details through. appstyles: ./src/scss/app.scss unfortunately autoprefix or css fix not working webpack 😞

webpack.config.js

const webpack = require('webpack'); const path = require('path'); const extracttextplugin = require('extract-text-webpack-plugin'); const htmlwebpackplugin = require('html-webpack-plugin'); const cleanwebpackplugin = require('clean-webpack-plugin');  const bootstrapentrypoints = require('./webpack.bootstrap.config');  const extractplugin = new extracttextplugin({   filename: '[name].css' }); const dist_dir = path.resolve(__dirname, 'dist'); const src_dir = path.resolve(__dirname, 'src');  const config = {   // entry: [src_dir + "/index.js"],   entry: [src_dir + "/index.js",bootstrapentrypoints.dev],   output: {     path: dist_dir,     filename: "bundle.js"     // publicpath: "/app/"   },   module: {     loaders: [       {         test: /\.jsx?/,         exclude: /node_modules/,         include: src_dir,         loader: 'babel-loader',         query:{           presets: ['es2015', 'stage-2']         }       },       {         test: /\.scss$/,         use: extractplugin.extract({           use: [             {               loader: 'css-loader',             },             {               loader: 'postcss-loader',               options: {                 plugins: (loader) => [                   require('autoprefixer')({                     browsers: ['last 2 version']                   }),                   require('postcss-flexbugs-fixes')(),                   require('css-mqpacker')                 ]               }             },             {               loader: 'sass-loader',             }           ]         })       },       {         test: /\.html$/,         use: ['html-loader']       },       {         test: /\.(jpeg|png)$/,         use: [           {             loader: 'file-loader',             options: {               name: '[name].[ext]',               // outputpath: 'img/',               publicpath: 'img/'             }           }         ]       },       // { test: /\.(woff2?|svg)$/, loader: 'url-loader?limit=10000' },       { test: /\.(woff2?|svg)$/, use: 'url-loader?limit=10000&name=fonts/[name].[ext]' },       // { test: /\.(ttf|eot)$/, loader: 'file-loader' },       { test: /\.(ttf|eot)$/, use: 'file-loader?name=fonts/[name].[ext]' },       {         test: /\.html$/,         use: [           {             loader: 'file-loader',             options: {               name: '[name].[ext]',             }           }         ],         exclude: path.resolve(__dirname, 'src/index.html')       }     ]   },   plugins:[     extractplugin,     new htmlwebpackplugin({       filename: 'index.html',       template: 'src/index.html'     }),     new cleanwebpackplugin(['dist'])   ] };  module.exports = config; 


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -