var HtmlWebpackPlugin = require('html-webpack-plugin'); var ExtractTextPlugin = require('extract-text-webpack-plugin'); var path = require("path"); module.exports = { entry: ['./src/index.js'], output: { path: path.join(__dirname, "./dist/"), filename: "main.js", }, module:{ rules:[ { test:/\.sass$/, use: ExtractTextPlugin.extract({ fallback:'style-loader', use:['css-loader','sass-loader'] }) } ] }, plugins: [ new ExtractTextPlugin({filename:'style.css'}), new HtmlWebpackPlugin({ hash: true, title: 'Weather for Philadelphia, PA', template: './src/index.html', path: path.join(__dirname, "./dist/"), filename: 'index.html', meta: { viewport: 'width=device-width, initial-scale=1, shrink-to-fit=no', } }), ] }