forked from sjoerdapp/styleguide2
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwebpack.dev.config.js
More file actions
49 lines (47 loc) · 1.13 KB
/
Copy pathwebpack.dev.config.js
File metadata and controls
49 lines (47 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
'use strict'; // eslint-disable-line strict
const path = require('path');
const webpack = require('webpack');
const HtmlWebpackPlugin = require('html-webpack-plugin');
const pkg = require('./package.json');
module.exports = {
devtool: 'eval-source-map',
entry: {
landing: './landing/index.js'
},
output: {
path: path.join(__dirname, 'build'),
filename: 'bundle.js',
publicPath: ''
},
module: {
loaders: [{
test: /\.js$/,
loaders: ['react-hot', 'babel'],
exclude: /node_modules/,
},
{
test: /\.styl$/,
loader: 'style-loader!css-loader?modules&importLoaders=1&localIdentName=[name]__[local]___[hash:base64:5]!stylus-loader'
},
{
test: /\.css$/,
loader: 'style!css?modules',
include: /flexboxgrid/,
},
{
test: /\.svg$/,
loader: 'svg-loader'
}]
},
devServer: {
historyApiFallback: true
},
plugins: [
new webpack.NoErrorsPlugin(),
new HtmlWebpackPlugin({
title: 'Styleguide Boilerplate',
template: './landing/index.ejs',
inject: 'body'
})
]
};