@loadable/webpack-plugin
LoadablePlugin
Create a webpack loadable plugin.
Arguments | Description |
---|---|
options | Optional options |
options.filename | Stats filename (default to loadable-stats.json ) |
options.outputAsset | Always write stats file to the output.path directory. Defaults to true |
options.writeToDisk | Accepts boolean or object . Always write stats file to disk. Default to false . |
options.writeToDisk.filename | Write assets to disk at given filename location |
new LoadablePlugin({ filename: 'stats.json', writeToDisk: true })
Writing file to disk can be useful if you are using
razzle
orwebpack-dev-server
.