I have an express
API I'm using in my app so I am using webpack-dev-middleware
and webpack-hot-middleware
.
I'm trying to figure out how to get the webpack --color
option when I use webpack
through the API.
This is what I have right now:
const webpack = require('webpack')
const webpackConfig = require('../../webpack.config')
const compiler = webpack(webpackConfig)
const webpackDevMiddleware = require('webpack-dev-middleware')(compiler, {
noInfo: true
})
const webpackHotMiddleware = require('webpack-hot-middleware')(compiler)
app.use(webpackDevMiddleware)
app.use(webpackHotMiddleware)
I am currently using webpack@2.2.0-rc.3
.