Skip to content

Instantly share code, notes, and snippets.

@SherryH
Created April 30, 2018 09:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SherryH/c7d17c6ea4635e3b7df499a95c9a67bf to your computer and use it in GitHub Desktop.
Save SherryH/c7d17c6ea4635e3b7df499a95c9a67bf to your computer and use it in GitHub Desktop.
const path = require('path');
module.exports = {
devtool: 'cheap-module-eval-source-map',
entry: path.join(__dirname, './src/index.js'),
output: {
path: path.join(__dirname, './dist'),
filename: 'main.js'
},
devServer: {
publicPath: './dist/'
},
module: {
rules: [
{
test: /\.js$/,
exclude: /node_modules/,
loader: 'babel-loader'
},
{
test: /\.css$/,
use: ['style-loader', 'css-loader']
}
]
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment