Instantly share code, notes, and snippets.

What would you like to do?
Webpack code splitting configuration example
module.exports = {
entry: {
main: './src/app.js',
output: {
// `filename` provides a template for naming your bundles (remember to use `[name]`)
filename: '[name].bundle.js',
// `chunkFilename` provides a template for naming code-split bundles (optional)
chunkFilename: '[name].bundle.js',
// `path` is the folder where Webpack will place your bundles
path: './dist',
// `publicPath` is where Webpack will load your bundles from (optional)
publicPath: 'dist/'

This comment has been minimized.

jovanliuc commented Jan 30, 2018

and just kick-off of an extremely simple webpack-config demo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment