Kent C. Dodds
Utah
1 wife, 3 kids
PayPal, Inc.
@kentcdodds
git clone https://github.com/kentcdodds/es6-todomvc.git
cd es6-todomvc
npm run setup:fem
npm start
open http://localhost:8080
And hundreds more...
CommonsChunkPlugin
ExtractTextWebpackPlugin
DedupePlugin
PrefetchPlugin
And many more...
entry
output
git checkout -f FEM/01.0-add-webpack
* Now available by default in the latest versions of Node!
You don't need node-nightly anymore
git checkout -f FEM/01.1-debug-webpack
git checkout -f FEM/01.2-require-everything
git checkout -f FEM/01.3-explicit-deps
git checkout -f FEM/01.4-transpile
CSS Loader
body:before {
content: '😀';
font-size: 60px;
}
Style Loader
<style>body:before{content:'😀';font-size:60px;}</style>
*at runtime
git checkout -f FEM/01.5-css
bootstrap.js
webpackHotUpdate
git checkout -f FEM/01.6-hmr
git checkout -f FEM/02.0-init-karma
git checkout -f FEM/02.1-add-assertions
git checkout -f FEM/02.2-add-webpack
git checkout -f FEM/02.3-add-coverage
git checkout -f FEM/02.4-cover-everything
git checkout -f FEM/03.0-es6ify
Tree shaking creates dead code.
-Tobias Koppers
Tree shaking excludes exports from modules where it can be detected the export is not used. Uglify then deletes the dead code.
-me 😉
git checkout -f FEM/05.0-code-splitting
git checkout -f FEM/05.1-code-splitting
App 3
App 4
App 2
App 1
git checkout -f FEM/06.0-commons-chunk
git checkout -f FEM/06.1-longterm-caching
git checkout -f FEM/06.2-extract-css
git checkout -f FEM/07.0-offline
git checkout -f FEM/07.1-deploy-surge
export SURGE_LOGIN=<your-email>
export SURGE_TOKEN=<your-token>
node_modules/.bin/surge --project dist --domain https://todomvc-<your-name>.surge.sh
SET SURGE_LOGIN=<your-email>
SET SURGE_TOKEN=<your-token>
node_modules/.bin/surge --project dist --domain https://todomvc-<your-name>.surge.sh
*nix
windows