Make measure UI exported for teamwork
const measureExport = require('measure-export');
const me = measureExport({
// options
})
// Get dynamic webpack config
me.getWebpackConfig({ prod: false }).then(config => {})
// Get webpack middlewares, like hot middleware and dev middleware
me.getMiddlewares().then(({ hot, dev }) => {})
// Run webpack build processing
me.build().then(states => {})
Print debugging information
- Type:
boolean
- Default:
false
See webpack's devtool
option
false
means turn off source-map
true
means turn on source-map, (that is to say, webpack devtool
option assigned to be source-map
)
- Type:
boolean
- Default:
false
template path about html-webpack-plugin
- Type:
string
- Default:
nps.join(__dirname, 'index.html')
It's belong to the options of friendly-errors-webpack-plugin
the directory of dist when running build
- Type:
string
- Default:
nps.join(process.cwd(), 'dist')
The matched patterns in context
which would be shown in navigator (left view)
- Type:
string[] | string
- Default:
['**/*.{psd,html,htm}']
Language in UI by default
- Type:
string
- Default:
en-us
Enable webpack hot module replacement and file watching or not
measureExport({
hot: false
})
.getMiddlewares()
.then(({ hot }) => {
hot // undefined
})
- Type:
boolean
- Default:
true
The identifier of the current process
- Type:
string
- Optional
webpack configuration updater
- Type:
config => updatedConfig
- IPC (multi-worker)