Commit graph

271 commits

Author SHA1 Message Date
Arunoda Susiripala
4b143fc232 Make sure dynamic imports works on Windows (#3641)
* Make sure dynamic imports works on Windows

* Fix an issue with the load test firmware.

* Fix symlink creation on Unix
2018-01-31 08:35:10 +01:00
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
Arunoda Susiripala
0b6575b470 Use our static file rendering machanism to serve pages.
This should work well since the file path for a page is predictable.
2018-01-13 10:36:50 +05:30
Tim Neutkens
81479eb601 Update yarn.lock 2017-10-19 23:49:09 +02:00
Kevin Decker
f7d2b96d28 Update yarn deps for react hot loader (#3122) 2017-10-17 21:05:21 +02:00
Tim Neutkens
7271970629 Upgrade styled-jsx (#3101) 2017-10-15 22:56:40 +02:00
Zach Brown
8873735de3 Upgrade react-hot-loader (add React 16 Support) (#3072) 2017-10-11 05:44:34 +05:30
Giuseppe
0262845a36 Update styled-jsx to version 2.0.2 (#3069) 2017-10-10 23:01:11 +02:00
Arunoda Susiripala
feff71ecac Update styled-jsx to version 2.0.1 2017-10-09 22:04:20 +05:30
Giuseppe
b0bf03407c Update styled-jsx into 2.0.1-beta.5 (#3052) 2017-10-08 15:43:55 +05:30
Arunoda Susiripala
1cca97cb5d Update styled-jsx into 2.0.1-beta.4 2017-10-08 03:06:07 +05:30
Arunoda Susiripala
a761aa5b97 Release 4.0.0-beta.4 2017-10-07 01:02:35 +05:30
Tim Neutkens
949296baf1 Upgrade styled-jsx@beta to latest version (#3045) 2017-10-05 15:39:16 -04:00
Arunoda Susiripala
2eb8b0e983 Add styled-jsx 2.0 beta support. (#3039) 2017-10-04 23:46:06 +05:30
Tim Neutkens
531d0a3068 Upgrade dependencies (#2998) 2017-09-27 20:11:02 +02:00
Arunoda Susiripala
56662b4d84 Add/with router (#2870)
* Add withRoute HOC

Rebased (squashed)
- removed routerToProps
- updated hoist-non-react-statics
- improved propTypes

* Expose the whole Router instead of the route.

* Make the example simple.

* Update examples and the readme.

* Add a test case.
2017-08-30 19:37:12 +05:30
Arunoda Susiripala
4833e2ffb5 [WIP] Add more HMR test cases (#2599)
Add more HMR test cases
2017-07-20 21:30:45 +05:30
Arunoda Susiripala
412389d64e Update yarn.lock 2017-07-17 11:13:28 +05:30
Arunoda Susiripala
62a6247753 3.0.1-beta.14 2017-07-15 16:26:25 +05:30
Tim Neutkens
ee29abb8d1 Add propType check with validation (#2516) 2017-07-09 18:42:20 +05:30
Arunoda Susiripala
feaa1934d8 Update yarn.lock 2017-07-09 10:04:53 +05:30
Arunoda Susiripala
64aca55f8b Update yarn.lock 2017-07-08 11:11:55 +05:30
Arunoda Susiripala
0c7089f856 Remove mitt and use an internal EventEmitter (#2477)
This fixes one of the crucial bug in Next.js
The issue happens when you try to load a page when it's
prefetching.
With mitt, it only fires the first registered event.
2017-07-06 12:19:33 +05:30
Leo Lamprecht
c050ba46bf Support for Prettier 1.5.x added (styled-jsx) 2017-07-03 17:15:52 +02:00
Arunoda Susiripala
e2a8cc411a 3.0.1-beta.7 2017-07-03 11:09:11 +05:30
Arunoda Susiripala
761a965bfb 3.0.1-beta.6 2017-07-02 09:17:40 +05:30
Arunoda Susiripala
66b31b62da Update yarn.lock 2017-06-29 00:51:42 +05:30
Arunoda Susiripala
c92bdef8b5 Merge master into v3-beta. 2017-06-26 23:21:52 +05:30
Arunoda Susiripala
7247a36ef8 Update styled-jsx to 1.0.6. (#2368)
This fixes the styled-jsx HMR not working error
2017-06-26 23:02:27 +05:30
C. T. Lin
213d7a82d1 update webpack to v3 (#2349)
* update webpack to v3

* Use exact versions.
2017-06-23 10:44:40 +05:30
Luke Edwards
8d0fdc09f7 [Beta] Switch from Fly to Taskr (#2307)
* switch from fly to taskr

* update taskfile
2017-06-22 15:52:13 +02:00
Luke Edwards
ba5b05a276 [Stable] Move from Fly to Taskr (#2306)
* switch from fly to taskr

* update taskfile
2017-06-22 15:51:49 +02:00
Arunoda Susiripala
8277d43190 Rewrite url when exporting only if there's a href. (#2316) 2017-06-20 14:07:36 +05:30
Arunoda Susiripala
319a2144f3 Merge master into v3-beta. 2017-06-16 21:55:46 +05:30
Arunoda Susiripala
a33a01fba5 2.4.4 2017-06-16 21:51:03 +05:30
Arunoda Susiripala
25f967edfc 3.0.0-beta15 2017-06-16 18:55:05 +05:30
Jayden Seric
f36b4f9b4a Update Webpack to v2.6.1 (#2271)
* Update Webpack to v2.6.1.

Also, added the ^ so that future patches won’t be missed. Should fix https://github.com/zeit/next.js/issues/2244.

* Update package.json
2017-06-16 18:47:13 +05:30
Arunoda Susiripala
f9ef3c7cda Update yarn.lock 2017-06-12 23:06:34 +05:30
Iain Collins
5fa03f941d Updating react & react-dom versions (#2212)
Ran into blocking compatibility issues (unable to start an app even  with the simplest possible example) when trying to upgrade the next.js version on an older project that used react/react-dom@15.4.2.

This was resolved by upgrading react/react-dom to the latest version (15.5.4) so updating dependencies and peerDependencies to reflect the latest version.

Raised in issue #2150
2017-06-09 23:49:31 +05:30
Arunoda Susiripala
13a51e0a75 Merge master into v3-beta. 2017-06-07 11:43:05 +05:30
Arunoda Susiripala
7cd2bb69ea Squashed commit of the following:
commit ced48c3fcfd1880016b08590e1b50827247b7cfb
Author: Arunoda Susiripala <arunoda.susiripala@gmail.com>
Date:   Wed Jun 7 11:28:43 2017 +0530

    Make sure XSS fix doesn't break our 404 support.

commit d40c833aa16660d547df785bb52e69ecf9a717f2
Author: Arunoda Susiripala <arunoda.susiripala@gmail.com>
Date:   Wed Jun 7 09:08:41 2017 +0530

    Prevent url path based XSS attacks.
2017-06-07 11:37:28 +05:30
Guillermo Rauch
fa5dc4293d update lock 2017-06-06 13:36:59 -07:00
Guillermo Rauch
3a36aeec68 update yarn.lock 2017-06-06 13:32:27 -07:00
Arunoda Susiripala
f342624f14 Merge master with v3-beta 2017-06-05 15:19:33 +05:30
Guillermo Rauch
62a41605aa Release 3.0.0-beta9 2017-06-02 07:21:36 -07:00
Arunoda Susiripala
e1a9febe28 Get latest master into v3 (#2139)
* Merge branch 'master' into v3-beta

* Add send back to v3-beta.
2017-06-02 10:35:04 +05:30
Guillermo Rauch
850a931e88 Merge branch 'master' into v3-beta 2017-06-01 18:30:57 -07:00
Arunoda Susiripala
ed3618f035 Fix test failures (#2129)
* Fix test failures due to styled-jsx change.

* Update styled-jsx to the latest.
2017-06-01 10:34:21 +05:30
Tim Neutkens
25afe27211 Update styled jsx to 1.x (#2119) 2017-05-31 07:43:17 +02:00
Tim Neutkens
e97ed52b3d move dep to devdep 2017-05-15 20:49:59 +02:00
Arunoda Susiripala
4d0147385c Merge v3-beta in dynamic-imports 2017-05-15 09:41:42 +05:30
Arunoda Susiripala
e613882010 Update tests for the recent changes. 2017-05-15 09:31:02 +05:30
Arunoda Susiripala
6f674b8c0a Get rid of realPathname for consistant page file structure. 2017-05-10 20:01:42 -07:00
Arunoda Susiripala
98ed666ca6 merge master into next-export 2017-05-10 19:01:01 -07:00
Arunoda Susiripala
7b193f1aa7 Add basic test setup 2017-05-09 16:24:34 -07:00
Grokling
7c8d0246e2 Add rehydration to example/aphrodite (#1858)
* Add rehydration to example/aphrodite

* linting

* replaced yarn.lock
2017-05-10 00:33:39 +02:00
Arunoda Susiripala
f602f6dc1e Copy all the static assests to .out 2017-05-07 15:47:40 -07:00
Guillermo Rauch
9a2edfd040 Release 2.3.0 2017-05-04 07:22:17 -07:00
Arunoda Susiripala
686dd4c4dd Merge master into dynamic-import. 2017-04-27 08:48:43 -07:00
Guillermo Rauch
ae983c6e3f update lockfile 2017-04-23 12:35:56 -07:00
Arunoda Susiripala
ea77b41570 Use babel-loader 7 beta. (#1495)
* Use babel-loader 7 beta.
This will get rid of the DeprecationWarning printed while
starting next.
Also this is the version recommened to use with Webpack 2.

* Update to the babel-loader-7
2017-04-22 07:18:53 +05:30
Arunoda Susiripala
90ea471aa7 Merge master into dynamic-import. 2017-04-18 21:42:21 +05:30
Arunoda Susiripala
f82e52935d Implement ETag support for server rendered pages. (#1693) 2017-04-18 21:15:42 +05:30
Arunoda Susiripala
e0f71d8448 Use babel-preset-env instead of babel-preset-latest. (#1701)
Here we don't use the full capabilities of babel-preset-env.
But it's recommended to use it without browser configs as
a substitute for babel-preset-latest.
That's why we did this.
2017-04-18 19:28:34 +05:30
Arunoda Susiripala
f51300f14b Add core import() support. 2017-04-17 21:03:40 +05:30
C. T. Lin
8e6615dcf9 upgrade react to v15.5 and use prop-types instead of React.PropTypes (#1684)
* upgrade react to v15.5 and use prop-types instead of React.PropTypes

* Update package.json
2017-04-11 00:05:26 +05:30
Guillermo Rauch
0ed3978a51 add lock 2017-04-07 11:41:43 -07:00
Robin Millette
8c19286a4d Add glob dependency (glob-promise peer). (#1624) 2017-04-05 09:22:32 +02:00
Tim Neutkens
7f0591896a Use latest version of Next for all examples (#1597)
* Use latest for all examples

* Update yarn.lock
2017-04-03 09:46:35 +05:30
Andrey Okonetchnikov
66ab661d4c chore(lint): Use lint-staged with standard --fix to run linter only on staged files. (#1519) 2017-03-30 04:51:11 +05:30
Guillermo Rauch
0a452ba3e4 Release 2.0.0-beta.40 2017-03-25 13:08:16 -07:00
Arunoda Susiripala
32af8294a7 Load the main JS bundle in production with async (#1485)
* Use a webpack plugin to combine assets.

* Add comments and make this releseable.

* Fix some typos.

* Fix some typos.
2017-03-24 13:21:34 +05:30
Guillermo Rauch
59433fc88e Release 2.0.0-beta.39 2017-03-16 13:09:37 -07:00
Guillermo Rauch
458f33f6f8 Release 2.0.0-beta.38 2017-03-14 11:58:28 -07:00
Guillermo Rauch
45bd239827 Release 2.0.0-beta.37 2017-03-13 10:49:15 -07:00
Arunoda Susiripala
57099a544c Use mitt instead of EventEmitter. (#1398)
EventEmitter is quite bit and mitt is a pretty good/small replacement.
2017-03-13 10:04:30 +05:30
Arunoda Susiripala
f9286f74bf [WIP] Improve test setup (#1372)
* Run tests serially.

* Make test result verbose.

* Don't wait until closing the browser.

* Add some debug logs.

* Add bailing support.

* Get the browser with a timeout.

* Add some comments.

* Remove istanbul babel tranformation.
Jest already do it and it's breaking our coveralls hit.
2017-03-08 13:23:05 +05:30
Guillermo Rauch
e15f06071d update yarn 2017-03-07 14:12:50 -08:00
Tim Neutkens
2a1f8ad387 Fix linting errors in standard 9.0 (#1333)
* Fix linting errors in standard 9.0

* Update lockfile
2017-03-02 16:17:41 -08:00
Guillermo Rauch
7deca93a10 Release 2.0.0-beta.36 2017-02-28 15:02:33 -08:00
Guillermo Rauch
012c4d1f81 Release 2.0.0-beta.35 2017-02-27 21:50:33 -08:00
Guillermo Rauch
8399ea70d4 Release 2.0.0-beta.33 2017-02-26 11:47:50 -08:00
Arunoda Susiripala
d3b1ead149 Implement "on demand entries" (#1111)
* Add a plan for dynamic entry middleware.

* Use dynamic pages middleware to load pages in dev.

* Add the first version of middleware but not tested.

* Integrated.

* Disable prefetching in development.
Otherwise it'll discard the use of dynamic-entries.

* Build custom document and error always.

* Refactor code base.

* Change branding as on-demand entries.

* Fix tests.

* Add a client side pinger for on-demand-entries.

* Dispose inactive entries.

* Add proper logs.

* Update grammer changes.

* Add integration tests for ondemand entries.

* Improve ondemand entry disposing logic.

* Try to improve testing.

*  Make sure entries are not getting disposed in basic integration tests.

* Resolve conflicts.

* Fix tests.

* Fix issue when running Router.onRouteChangeComplete

* Simplify state management.

* Make sure we don't dispose the last active page.

* Reload invalid pages detected with the client side ping.

* Improve the pinger code.

* Touch the first page to speed up the future rebuild times.

* Add Websockets based pinger.

* Revert "Add Websockets based pinger."

This reverts commit f706a49a3d886d0231259b7a1fded750ced2e48f.

* Do not send requests per every route change.

* Make sure we are completing the middleware request always.

* Make sure test pages are prebuilt.
2017-02-26 11:45:16 -08:00
Tim Neutkens
408633c1dc Remove traces of glamor (#1286)
* Remove traces of glamor

As talked about with @rauchg. Glamor takes up around 60KB of the bundle (pre-gzip). Since styled-jsx is the way to go now and we support adding glamor by the user we should remove it as dependency cause it is bundled even when not used.

Added rehydration to the example, since we did that in our code.

There is only one thing I'm not sure about and want to discuss:
what should we do with next/css. Right now I added a throw for when it is imported. I'm not sure if we should do that / some other way to notify the user it has been removed. The reasoning behind the throw is that when we would do a console.warn the user would see 'css.default.<X>' not found because we don't have the glamor dependency anymore.

* Update yarn.lock

* Remove test for styles
2017-02-26 17:58:00 +05:30
Guillermo Rauch
bb526fdf53 bump unfetch 2017-02-25 19:31:50 -08:00
Guillermo Rauch
e7c85e0162 Revert "Remove unfetch because of production build errors. (#1288)"
This reverts commit 756a32aefd.
2017-02-25 19:28:24 -08:00
Arunoda Susiripala
756a32aefd Remove unfetch because of production build errors. (#1288)
See https://github.com/zeit/next.js/pull/1278#issuecomment-282528628
2017-02-26 08:26:55 +05:30
Arunoda Susiripala
fb496b7c9a Run tests in Travis. (#1247)
* Run tests in Travis.

* Update deps and config.

* Update jest config.

* Disable a test temp.

* Increase the timeout.
2017-02-22 23:38:49 +05:30
Guillermo Rauch
c866540601 Release 2.0.0-beta.32 2017-02-20 15:51:19 -08:00
Guillermo Rauch
b621f2d840 Release 2.0.0-beta.30 2017-02-17 02:02:07 -03:00
Leo Lamprecht
48d8e4f246
Updated lockfile for yarn 2017-02-17 00:01:21 +01:00
Arunoda Susiripala
00e7a29731 Move the test babel setup to the main babelrc file. (#1163)
* Move the test babel setup to the main babelrc file.

* Add es2015 preset.
2017-02-16 00:43:31 +05:30
Tim Neutkens
fca186f9e7 Remove pre-gzip support (#1155) 2017-02-15 15:49:45 +01:00
Arunoda Susiripala
14c86bef1d Introduce a simple prefetching solution (#957)
* Implement a very simple prefetching solution.

* Remove next-prefetcher.

* Require 'whatwg-fetch' only in the client.

* Use xhr in the code.

* Use a simple fetching solution.

* Fix 404 and xhr status issue.

* Move the prefetching implementation to next/router.

* Add deprecated warnning for next/prefetch

* Run only 2 parellel prefetching request at a time.

* Change xhr to jsonPageRes.

* Improve the prefetching logic.

* Add unit tests covering the Router.prefetch()

* Update examples to use the new syntax.

* Update docs.

* Use execOnce() to manage warn printing.

* Remove prefetcher building from the flyfile.js
Because, we no longer use it.
2017-02-15 14:22:22 +05:30
Guillermo Rauch
507e8c2ca4 Release 2.0.0-beta.26 2017-02-14 12:31:34 -03:00
Arunoda Susiripala
9d529ea0b1 Remove babell-plugin-transform-react-constant-elements. (#1102)
* Remove babell-plugin-transform-react-constant-elements.
With this, our shared-modules example's counter won't work in
production mode. (as this plugin enabled)
So, we could see more issues like this.
That's why we don't need this at this time.

* Update package.json.
2017-02-14 07:37:34 +05:30
Tim Neutkens
77c14f96b1 Add react-jsx-source for development (#1115) 2017-02-14 07:24:01 +05:30
Tim Neutkens
faef6e48e0 Remove pure-class-to-function (#1077)
* Optimize React

* Remove unused preset

* Remove pure-class-to-function
2017-02-11 07:42:12 +05:30
Tim Neutkens
250c066de5 Optimize React on next build (#1075)
* Optimize React

* Remove unused preset
2017-02-11 04:05:13 +09:00
Luke Edwards
864fe60a15 Write executable files to dist/bin (#1059)
* update to fly@2.0.4

* write executable dist/bin files
2017-02-09 21:37:18 +01:00
Luke Edwards
839fb1c05c [WIP] Migrate from Gulp to Fly (#965)
* install fly & plugins

* start flyfile conversion

* install node-notifier directly

* send task notifications

* upgrade to fly@2.0.1

* fix watch rebuilds

* compile in parallel

* remove gulp-related deps

* enable start|stop-chromedriver

* run build before watching

* extract webpack config

* fix webpack build

* use serial chain within 'build' -- faster

* update to fly-watch@1.1.0

* generate new yarn.lock after rebase

* rename tasks; use fly-esnext (async/await)

* bump fly deps (node4 supp)

* remove destructured assignment

* import latest package.json changes
2017-02-09 20:33:08 +01:00
Arunoda Susiripala
355c984ed8 Testing: use a better way to get a port to the test app (#753)
* Randomize the port returned from test util's findPort().

* Use http's server.listen() to bind to a random available port.

* Update yarn.lock

* Update yarn.lock
2017-02-09 14:40:09 +01:00
Arunoda Susiripala
55f48563a0 Add babel-preset-latest support. (#1027)
* Add babel-preset-2016 support.
This adds the support for Exponentiation operator (**)

* Use babel-preset-latest.

* Remove babel-plugin-transform-async-to-generator in favor of babel-plugin-latest
It has es2017 preset and it comes with the above plugin.
2017-02-08 13:05:25 +01:00
Guillermo Rauch
8dfbbd3674 Release 2.0.0-beta.24 2017-02-06 11:05:07 -03:00
Guillermo Rauch
3e34430f74 Release 2.0.0-beta.21 2017-02-02 11:13:43 -08:00
Guillermo Rauch
f944b50ffe Release 2.0.0-beta.20 2017-01-27 10:57:16 -08:00
nkzawa
293029a36a update yarn.lock 2017-01-26 18:30:20 +09:00
Guillermo Rauch
3765b14993 bump styled-jsx 2017-01-20 18:26:27 -08:00
Guillermo Rauch
0b2b56f174 Release 2.0.0-beta.17 2017-01-12 08:36:29 -08:00
Arunoda Susiripala
1dc52dbc6c New test setup (#640)
* Use jest-cli instead of gulp plugin.

* Use jest-cli instead of gulp plugin.

* Move fixtures into the examples dir.

* Move test code of example app to the basic example.

* Add isolated tests for server/resolve

* Allow tests to use cheerio.

* Use portfinder to get a unique port.

* Move back integration tests into the example dir.

* Introduce next-test-utils.

* Remove gulp-jest

* Add coveralls support.

* Use transpiled version of code in dist.
This is to make sure same file gets covered
by both unit/isolated tests and integration tests.

* Add support for source maps.

* Use code from dist always.

* Use nyc to stop instrument.

* Add integration test suite for production usage.

* Use jest-cli.

* Add support for running e2e tests.

* Check gzipPath with fs.stat before serving
Otherwise, serve package might throw issues other than ENOENT

* Install chromedriver with npm install.

* Install chrome on travis-ci.

* Add --forceExit to Jest.

* Run tests only on Node v6.
That's because selenium-webdriver only supports
Node 6 LTS.

* Use chromedriver NPM module to install chromedriver.

* Use wd as the webdriver client.

* Run chromedriver before tests.

* Run travis for both node 4 and 6

* Remove unwanted npm install script.

* Move some common text utilities to next-test-utils

* Add lint checks and testing in npm prepublish hook.

* Use npm on travis-ci.
We are having some caching issues with yarn and chromedriver.

* Make tests work on windows.\n But chromedriver doesn't work.

* Clean up dependencies.

* Run chromedriver in background without any tools.

* Fix a typo in the code.

* Use ES6 features used in node4 inside the gulpfile.

* Add some comments.

* Add support for running in windows.

* Stop chromedriver properly on windows.

* Fix typos.
2017-01-12 13:14:49 +09:00
Arunoda Susiripala
b7e57f9347 Implement "Immutable build artifacts" feature (#745)
* Write BUILD_ID when building.
It's a random id (uuid.v4())

* Add buildId to the core JS files.

* Add immutable cache-control header.
Only if the buildId is matched.

* Set '-' as the dev buildId always.

* Add buildId handling for JSON pages.
2017-01-11 12:16:18 -08:00
Arunoda Susiripala
88e4adfc2a Add case sensitive checks for imports and JSON page resolver (#697)
* Add case-sensitive-paths-webpack-plugin plugin.

* Add case-sensitive check for server/resolve.
2017-01-08 18:12:29 -08:00
Arunoda Susiripala
042ffa1175 Add correct content-type header for gzipped version. (#705) 2017-01-08 18:12:10 -08:00
Guillermo Rauch
d387c52179 bump styled-jsx 2017-01-05 17:20:33 -08:00
Guillermo Rauch
05cbcb46af Release 2.0.0-beta.14 2017-01-05 13:03:52 -08:00
Guillermo Rauch
697010f9ae Release 2.0.0-beta.9 2016-12-31 12:37:31 -08:00
Arunoda Susiripala
165924b71b Add Gzip support for JSON pages (#571)
* Server JSON pages directly from the filesystem.

* Make Json pages even if there's an error.

* Implement much better page serving.

* Use JsonPagesPlugin in the production mode as well.

* Add gzip support for JSON pages.

* Use glob-promise instead of recursive-readdir

* Handle renderStatic 404 properly.

* Simply the gzip code.

* Cache already read JSON pages.

* Change JSON pages extension to .json.

* Fix HMR related issue.

* Fix hot-reload for .json solely on server.

* Properly clear cache on hot-reloader.

* Convert .js pages into .json page right inside the plugin.

* Fix gzipping .json pages.

* Remove unwanted json pages cleanup.

* Get rid of deprecated fs.exists for fs.access
2016-12-31 21:46:23 +09:00
Guillermo Rauch
56ca84bae2 Release 2.0.0-beta.6 2016-12-30 18:39:08 -08:00
nkzawa
1fbf324883 update yarn.lock 2016-12-30 16:19:09 +09:00
Arunoda Susiripala
29c226771c Add AOT gzip content-encoding support for main build files. (#565)
* Add AOT gzip content-encoding support.
Currently we only do this for
main.js and commons.js only.

* Remove unwanted await.

* Use Promise.all to gzip assets in parallel.
2016-12-29 14:38:19 -08:00
Guillermo Rauch
0c6efce5f0 yarn.lock (#528) 2016-12-27 18:24:33 -08:00