- Aggressive Merging
- Chunk
- Code Splitted
- Code Splitting
- Coffee Script
- CommonJS
- DLL
- Externals
- Harmony
- HTTP2 Aggressive Splitting
- Hybrid Routing
- Loader
- Mixed
- Multi Compiler
- Multi Part Library
- Multiple Entry Points
- Require Context
- Require Resolve
- Scope Hoisting
- Side Effects
- Source Map
- WebAssembly
- Web Worker
- Requests
- Building an Example
aggressive-merging
chunkhash
common-chunk-and-vendor-chunk
explicit-vendor-chunk
extra-async-chunk-advanced
extra-async-chunk
code-splitting-specify-chunk-name
named-chunks
example demonstrating merging of chunks with named chunks
two-explicit-vendor-chunks
code-splitted-require.context-amd
example demonstrating contexts in a code-split environment with AMD.
code-splitted-require.context
example demonstrating contexts in a code-split environment.
code-splitting
example demonstrating a very simple case of Code Splitting.
code-splitting-bundle-loader
example demonstrating Code Splitting through the bundle loader
code-splitting-harmony
code-splitting-native-import-context
code-splitting-specify-chunk-name
coffee-script
example demonstrating code written in coffee-script.
commonjs
example demonstrating a very simple program
dll
dll-user
externals
harmony
code-splitting-harmony
harmony-interop
harmony-library
harmony-unused
HTTP2 Aggressive Splitting
http2-aggressive-splitting
hybrid-routing
loader
example demonstrating the usage of loaders.
mixed
example demonstrating mixing CommonJs and AMD
multi-compiler
multi-part-library
multiple-entry-points
example demonstrating multiple entry points with Code Splitting.
require.context
example demonstrating automatic creation of contexts when using variables in
require
.
require.resolve
example demonstrating how to cache clearing of modules with
require.resolve
and
require.cache
.
scope-hoisting
side-effects
TypeScript
source-map
wasm-simple
example demonstrating simple import from a WebAssembly module
wasm-complex
example demonstrating top-level await and import of WebAssembly text format with wast-loader
web-worker
example demonstrating creating WebWorkers with webpack.
If you think an example is missing, please report it as issue. :)
- Run
yarn
in the root of the project.
- Run
yarn setup
in the root of the project.
- Run
yarn add --dev webpack-cli
in the root of the project.
- Run
node build.js
in the specific example directory. (Ex:
cd examples/commonjs && node build.js
)
Note: To build all examples run
npm run build:examples