1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
next.js/examples
Tim Neutkens e093441bad Universal Webpack (#3578)
* Speed up next build

* Document webpack config

* Speed up next build

* Remove comment

* Add comment

* Clean up rules

* Add comments

* Run in parallel

* Push plugins seperately

* Create a new chunk for react

* Don’t uglify react since it’s already uglified. Move react to commons in development

* Use the minified version directly

* Re-add globpattern

* Move loaders into a separate variable

* Add comment linking to Dan’s explanation

* Remove dot

* Add universal webpack

* Initial dev support

* Fix linting

* Add changes from Arunoda's work

* Made next dev works.
But super slow and no HMR support.

* Fix client side hot reload

* Server side hmr

* Only in dev

* Add on-demand-entries client + hot-middleware

* Add .babelrc support

* Speed up on demand entries by running in parallel

* Serve static generated files

* Add missing config in dev

* Add sass support

* Add support for .map

* Add cssloader config and fix .jsx support

* Rename

* use same defaults as css-loader. Fix linting

* Add NoEmitErrorsPlugin

* Add clientBootstrap

* Use webpackhotmiddleware on the multi compiler

* alpha.3

* Use babel 16.2.x

* Fix reloading after error

* Remove comment

* Release 5.0.0-univeral-alpha.1

* Remove check for React 16

* Release 5.0.0-universal-alpha.2

* React hot loader v4

* Use our static file rendering machanism to serve pages.
This should work well since the file path for a page is predictable.

* Release 5.0.0-universal-alpha.3

* Remove optional loaders

* Release 5.0.0-universal-alpha.4

* Remove clientBootstrap

* Remove renderScript

* Make sure pages bundles are served correctly

* Remove unused import

* Revert to using the same code as canary

* Fix hot loader

* Release 5.0.0-universal-alpha.5

* Check if externals dir exist before applying config

* Add typescript support

* Add support for transpiling certain packages in node_modules

Thanks to @giuseppeg’s work in https://github.com/zeit/next.js/pull/3319

* Add BABEL_DISABLE_CACHE support

* Make sourcemaps in production opt-in

* Revert "Add support for transpiling certain packages in node_modules"

This reverts commit d4b1d9babfb4b9ed4f4b12d56d52dee233e862da.

In favor of a better api around this.

* Support typescript through next.config.js

* Remove comments

* Bring back commons.js calculation

* Remove unused dependencies

* Move base.config.js to webpack.js

* Make sure to only invalidate webpackDevMiddleware one after other.

* Allow babel-loder caching by default.

* Add comment about preact support

* Bring back buildir replace

* Remove obsolete plugin

* Remove build replace, speed up build

* Resolve page entries like pages/day/index.js to pages/day.js

* Add componentDidCatch back

* Compile to bundles

* Use config.distDir everywhere

* Make sure the file is an array

* Remove console.log

* Apply optimization to uglifyjs

* Add comment pointing to source

* Create entries the same way in dev and production

* Remove unused and broken pagesGlobPattern

* day/index.js is automatically turned into day.js at build time

* Remove poweredByHeader option

* Load pages with the correct path.

* Release 5.0.0-universal-alpha.6

* Make sure react-dom/server can be overwritten by module-alias

* Only add react-hot-loader babel plugin in dev

* Release 5.0.0-universal-alpha.7

* Revert tests

* Release 5.0.0-universal-alpha.10

* Make sure next/head is working properly.

* Add wepack alias for 'next' back.

* Make sure overriding className in next/head works

* Alias react too

* Add missing r

* Fragment fallback has to wrap the children

* Use min.js

* Remove css.js

* Remove wallaby.js

* Release 5.0.0-universal-alpha.11

* Resolve relative to workdir instead of next

* Make sure we touch the right file

* Resolve next modules

* Remove dotjsx removal plugins since we use webpack on the server

* Revert "Resolve relative to workdir instead of next"

This reverts commit a13f3e4ab565df9e2c9a3dfc8eb4009c0c2e02ed.

* Externalize any locally loaded module lives outside of app dir.

* Remove server aliases

* Check node_modules reliably

* Add symlink to next for tests

* Make sure dynamic imports work locally.
This is why we need it: b545b519b2/lib/MainTemplate.js (L68)
We need to have the finally clause in the above in __webpack_require__.
webpack output option strictModuleExceptionHandling does that.

* dynmaic -> dynamic

* Remove webpack-node-externals

* Make sure dynamic imports support SSR.

* Remove css support in favor of next-css

* Make sure we load path from `/` since it’s included in the path matching

* Catch when ensurepage couldn’t be fulfilled for `.js.map`

* Register require cache flusher for both client and server

* Add comment explaining this is to facilitate hot reloading

* Only load module when needed

* Remove unused modules

* Release 5.0.0-universal-alpha.12

* Only log the `found babel` message once

* Make sure ondemand entries working correctly.
Now we are just using a single instance of OnDemandEntryHandler.

* Better sourcemaps

* Release 5.0.0-universal-alpha.13

* Lock uglify version to 1.1.6

* Release 5.0.0-universal-alpha.14

* Fix a typo.

* Introduce multi-zones support for mircofrontends

* Add section on css
2018-01-30 16:44:44 +01:00
..
active-class-name Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
basic-css Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
custom-server Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
custom-server-express Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
custom-server-fastify Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
custom-server-hapi Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
custom-server-koa Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
custom-server-micro Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
custom-server-nodemon Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
data-fetch Merge branch 'master' into fix/canary 2018-01-13 06:33:19 +01:00
form-handler Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
gh-pages Github gh-pages Example (#3383) 2017-12-08 18:17:04 -08:00
head-elements Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
hello-world Universal Webpack (#3578) 2018-01-30 16:44:44 +01:00
layout-component Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
nested-components Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
only-client-render-external-dependencies Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
page-transitions Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
parameterized-routing Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
progressive-render Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
root-static-files Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
shared-modules Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
ssr-caching Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
svg-components Fix SVG component example dependencies (#3448) 2017-12-13 01:44:11 -08:00
using-inferno Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
using-preact Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
using-router Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
using-with-router Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-absolute-imports Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-algolia-react-instantsearch Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-amp Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-ant-design Update Ant Design example (#3485) 2018-01-06 17:14:22 +01:00
with-antd-mobile Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-aphrodite Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-apollo Update withData.js (#3458) 2017-12-18 11:27:16 +01:00
with-apollo-and-redux [refactor] with-apollo-and-redux: 2.0.0 (#3484) 2017-12-27 19:57:57 +01:00
with-apollo-auth Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-asset-imports Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-babel-macros Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-cerebral Add Cerebral example (#2976) 2017-09-23 16:30:22 +02:00
with-configured-preset-env Upgrade React for all examples (#3113) 2017-10-17 08:11:46 +02:00
with-custom-babel-config Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-custom-reverse-proxy Ease running multiple examples at the same time with process.env.PORT (#2753) 2017-08-10 20:15:46 +02:00
with-cxs Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-data-prefetch Extend with-data-prefetch to handle advanced use cases (#3525) 2018-01-26 17:07:17 +01:00
with-dotenv Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-dynamic-import Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-electron Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-emotion Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-emotion-fiber pushing updated emotion example (#3344) 2017-12-05 16:46:06 -08:00
with-external-scoped-css Upgrade React for all examples (#3113) 2017-10-17 08:11:46 +02:00
with-fela Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-firebase-authentication Fix Doc in with-firebase-authentication (#3626) 2018-01-27 15:12:25 +01:00
with-firebase-hosting Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-flow Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-freactal Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-glamor Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-glamorous Fix glamorous example (#3462) 2017-12-18 11:28:57 +01:00
with-global-stylesheet Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-global-stylesheet-simple Add with-global-stylesheet-simple (#3157) 2017-10-23 20:25:16 +02:00
with-hashed-statics Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-higher-order-component examples: add create-next-app (#3377) 2017-12-02 20:30:17 -08:00
with-i18next Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-jest [with-jest] Upgrade to jest 22 and so remove raf deps (#3477) 2017-12-19 10:29:29 +01:00
with-kea Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-loading Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-markdown Add markdown-in-js example (#3410) 2017-12-06 18:20:38 -08:00
with-material-ui Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-material-ui-next Updated material-ui-next URI (#3509) 2017-12-28 16:25:11 +01:00
with-mobx Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-mobx-state-tree Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-next-routes Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-noscript examples: add create-next-app (#3377) 2017-12-02 20:30:17 -08:00
with-pkg Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-portals Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-prefetching Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-pretty-url-routing Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-react-ga Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-react-helmet Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-react-i18next Ease running multiple examples at the same time with process.env.PORT (#2753) 2017-08-10 20:15:46 +02:00
with-react-intl Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-react-md Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-react-toolbox Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-react-uwp Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-react-with-styles Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-reasonml Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-rebass Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-recompose Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-redux Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-redux-code-splitting Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-redux-observable Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-redux-reselect-recompose Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-redux-saga fix(store): product env cannot find module 'redux-devtools-extension'. (#3618) 2018-01-26 17:09:49 +01:00
with-reflux Examples/with reflux (#3476) 2017-12-19 10:33:01 +01:00
with-refnux Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-relay-modern Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-scoped-stylesheets-and-postcss Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-semantic-ui Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-sentry examples: add create-next-app (#3377) 2017-12-02 20:30:17 -08:00
with-shallow-routing Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-socket.io Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-static-export Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-styled-components Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-styled-jsx-plugins Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-styled-jsx-postcss Make styled-jsx configurable (#3050) 2017-10-15 19:54:57 +02:00
with-styled-jsx-scss Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-styletron Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-sw-precache Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-tailwindcss Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-typescript Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-universal-configuration Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-universal-configuration-runtime Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-url-object-routing Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-webpack-bundle-analyzer Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-webpack-bundle-size-analyzer Use canary for all example downloads (#3411) 2017-12-06 18:12:42 -08:00
with-zones Universal Webpack (#3578) 2018-01-30 16:44:44 +01:00
.babelrc Babelrc false babelrc (#1094) 2017-02-13 06:18:22 +09:00
.gitignore Remove yarn.lock from examples (#912) 2017-01-29 05:48:53 +05:30