webpack/examples
Tobias Koppers 33c907e1b7 Merge branch 'master' into next
# Conflicts:
#	examples/aggressive-merging/README.md
#	examples/chunkhash/README.md
#	examples/code-splitted-css-bundle/README.md
#	examples/code-splitted-require.context-amd/README.md
#	examples/code-splitted-require.context/README.md
#	examples/code-splitting-bundle-loader/README.md
#	examples/code-splitting-harmony/README.md
#	examples/code-splitting-native-import-context/README.md
#	examples/code-splitting-specify-chunk-name/README.md
#	examples/code-splitting/README.md
#	examples/coffee-script/README.md
#	examples/common-chunk-and-vendor-chunk/README.md
#	examples/common-chunk-grandchildren/README.md
#	examples/commonjs/README.md
#	examples/css-bundle/README.md
#	examples/dll-app-and-vendor/0-vendor/README.md
#	examples/dll-app-and-vendor/1-app/README.md
#	examples/dll-user/README.md
#	examples/dll/README.md
#	examples/explicit-vendor-chunk/README.md
#	examples/externals/README.md
#	examples/extra-async-chunk-advanced/README.md
#	examples/extra-async-chunk/README.md
#	examples/harmony-interop/README.md
#	examples/harmony-library/README.md
#	examples/harmony-unused/README.md
#	examples/harmony/README.md
#	examples/http2-aggressive-splitting/README.md
#	examples/hybrid-routing/README.md
#	examples/i18n/README.md
#	examples/loader/README.md
#	examples/mixed/README.md
#	examples/move-to-parent/README.md
#	examples/multi-compiler/README.md
#	examples/multi-part-library/README.md
#	examples/multiple-commons-chunks/README.md
#	examples/multiple-entry-points-commons-chunk-css-bundle/README.md
#	examples/multiple-entry-points/README.md
#	examples/named-chunks/README.md
#	examples/require.context/README.md
#	examples/require.resolve/README.md
#	examples/scope-hoisting/README.md
#	examples/source-map/README.md
#	examples/two-explicit-vendor-chunks/README.md
#	examples/web-worker/README.md
#	package.json
2018-02-13 10:18:53 +01:00
..
aggressive-merging Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
chunkhash Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitted-css-bundle Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitted-require.context Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitted-require.context-amd Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitting Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitting-bundle-loader Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitting-harmony Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitting-native-import-context Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitting-native-import-context-filter Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
code-splitting-specify-chunk-name Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
coffee-script Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
common-chunk-and-vendor-chunk Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
common-chunk-grandchildren Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
commonjs Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
dll Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
dll-app-and-vendor Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
dll-user Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
explicit-vendor-chunk Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
externals Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
extra-async-chunk Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
extra-async-chunk-advanced Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
harmony Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
harmony-interop Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
harmony-library Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
harmony-unused Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
http2-aggressive-splitting Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
hybrid-routing Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
i18n Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
loader Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
mixed Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
multi-compiler Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
multi-part-library Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
multiple-entry-points Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
named-chunks Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
node_modules added dll example with module 2015-10-13 16:19:11 +02:00
require.context Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
require.resolve Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
scope-hoisting Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
side-effects Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
source-map Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
two-explicit-vendor-chunks Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
wasm-simple Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
web-worker Merge branch 'master' into next 2018-02-13 10:18:53 +01:00
README.md Fix link to side-effects example 2017-11-29 11:52:09 -08:00
build-common.js change output from examples for js/ to dist/ 2018-01-04 21:39:29 +01:00
buildAll.js Refactor chunk graph 2018-01-19 19:21:30 +01:00
examples.js Refactor example scripts and test to allow nested folders 2017-07-27 13:24:56 +02:00
template-common.js hide buildAt in examples 2018-02-10 15:09:34 +01:00

README.md

Examples

Aggressive Merging

aggressive-merging

Chunk

chunkhash

common-chunk-and-vendor-chunk

explicit-vendor-chunk

extra-async-chunk-advanced

extra-async-chunk

code-splitting-specify-chunk-name

move-to-parent

multiple-commons-chunks

multiple-entry-points-commons-chunk-css-bundle

named-chunks example demonstrating merging of chunks with named chunks

two-explicit-vendor-chunks

Code Splitted

code-splitted-css-bundle

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

code-splitting example demonstrating a very simple case of Code Splitting.

code-splitting-bundle-loader example demonstrating Code Splitting through the builder loader

code-splitting-harmony

code-splitting-native-import-context

code-splitting-specify-chunk-name

Coffee Script

coffee-script example demonstrating code written in coffee-script.

CommonJS

commonjs example demonstrating a very simple program

Css Bundle

css-bundle

multiple-entry-points-commons-chunk-css-bundle

DLL

dll

dll-user

Externals

externals

Harmony

harmony

code-splitting-harmony

harmony-interop

harmony-library

harmony-unused

HTTP2 Aggressive Splitting

http2-aggressive-splitting

Hybrid Routing

hybrid-routing

i18n

i18n example demonstrating localization.

Loader

loader example demonstrating the usage of loaders.

Mixed

mixed example demonstrating mixing CommonJs and AMD

Multi Compiler

multi-compiler

Multi Part Library

multi-part-library

Multiple Entry Points

multiple-entry-points example demonstrating multiple entry points with Code Splitting.

Require Context

require.context example demonstrating automatic creation of contexts when using variables in require.

Require Resolve

require.resolve example demonstrating how to cache clearing of modules with require.resolve and require.cache.

Scope Hoisting

scope-hoisting

Side Effects

side-effects

Source Map

source-map

Web Worker

web-worker example demonstrating creating WebWorkers with webpack and the worker-loader.

Requests

If you think an example is missing, please report it as issue. :)

Building an Example

  1. Run npm install in the root of the project.
  2. Run npm link webpack in the root of the project.
  3. 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