* Introduce script tag based page loading system.
* Call ensurePage only in the dev mode.
* Implement router using the page-loader.
* Fix a typo and remove unwanted code.
* Fix some issues related to rendering.
* Fix production tests.
* Fix ondemand test cases.
* Fix unit tests.
* Get rid of eval completely.
* Remove all the inline code.
* Remove the json-pages plugin.
* Rename NEXT_PAGE_LOADER into __NEXT_PAGE_LOADER__
* Rename NEXT_LOADED_PAGES into __NEXT_LOADED_PAGES__
* Remove some unwanted code.
* Load everything async.
* Remove lib/eval-script.js
We no longer need it.
* Move webpack idle wait code to the page-loader.
Because that's the place to do it.
* Remove pageNotFound key from the error.
* Remove unused error field 'buildError'
* Add much better logic to normalize routes.
* Get rid of mitt.
* Introduce a better way to register pages.
* Came back to the mitt() based page-loader.
* Add link rel=preload support.
* Add assetPrefix support to add support for CDNs.
* Add assetPrefix support for preload links.
* Update readme.md
* Introduce better debug error handling
With this we are rendering runtime and debug errors inside
a it's own error root.
That gives us better error handling and control.
Also, now we are patching React core to capture runtime errors.
* Render the initial error on the server.
With this we are rendering runtime and debug errors inside
a it's own error root.
That gives us better error handling and control.
Also, now we are patching React core to capture runtime errors.
* Add better hash URL support.
1. Add scrolling to given id related to hash
2. Hash changes won't trigger getInitialProps
* Add some comments.
* Fix tests.
* Add some test cases.
* 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.
* 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
* 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.
* Using styled-jsx for with-jest example.
* Set the displayName of the wraped components.
Otherwise it won't get the correct displayName if the
original component doesn't provide it by using it's function name.
* Remember scroll position on error
* Added comment + check if lastScroll was set
* Remove check for lastAppProps
* Use events to make scroll persistence dev-only
* Return EventEmitter from next()
* Update next-dev.js
* Use service-worker to fetch only JSON pages.
We simply don't need to proxy other requests through that.
That's might cause some latency issues.
* Use a better regexp to identify JSON pages.
* Do not patch prototypes with render exposed only as a getter.
* Use Object.getOwnPropertyDescriptor to make things simpler.
* Get the prototype which has the render method.
* Make sure lastAppProps always have some value.
* Revert "Make sure lastAppProps always have some value."
This reverts commit b4ae722d9c1a4460e17dbdc041b111cbd492b2aa.
* Throw an error, if we found an empty object from getInitialProps.
* Add proper tests for getInitialProps empty check.
* compile _document using webpack
* don't emit the bundle file of _document.js
* exclude _document.js from minChunks of CommonsChunkPlugin
* handle creation/removal of pages/_document.js
* improve path handlings
* Immplement the initial singleton Router.
* Use the new SingletonRouter for HMR error handling.
* Use SingletonRouter inside the Link.
* Create an example app using the Router.
* Make the url parameter optional in Router.push and Router.replace
* Add a section about next/router in the README.
* Remove the use of CDN and bundle everything inside the app.
We still pre-build the prefetcher because it needs
different webpack config which only targets browsers
supports Service Workers.
* Remove cdn config item.
We no longer using it.
* Stop adding script tags when staticMarkup=true
* Remove babel-plugin-transform-remove-strict-mode NPM module.
* Register the service worker.
* Update prefetcher code to do prefetching.
* Implement the core prefetching API.
support "import <Link>, { prefetch } from 'next/prefetch'"
* Implement a better communication system with the service worker.
* Add a separate example for prefetching
* Fix some typos.
* Initiate service worker support even prefetching is not used.
This is pretty important since initiating will reset the cache.
If we don't do this, it's possible to have old cached resources
after the user decided to remove all of the prefetching logic.
In this case, even the page didn't prefetch it'll use the
previously cached pages. That because of there might be a already running
service worker.
* Use url module to get pathname.
* Move prefetcher code to the client from pages
Now we also do a webpack build for the prefetcher code.
* Add prefetching docs to the README.md
* Fix some typo.
* Register service worker only if asked to prefetch
We also clean the cache always, even we initialize
the service worker or not.
Earlier we add a event to init next.js when dom has loaded.
But if at that time dom is already loaded, next.js won't get init ever.
Now we are using domready NPM module which handle these for us.
* Add example app which demonstrate the problem.
* Add the first working version.
* Fix lint issues.
* Add README.md
* Use /_next/main.js as the main file URI
* Add the support for loading the core next bundle.
* Optimize the output by removing Next modules from pages.
* Use the same package.json as master use.
* Change the example repo's README for simpler instructions.
* Change example projects package.json to support next build and start.
* Change main.js into commons.js.
* Add support for hot core reload and errors.
* Introduce require based on eval-script.
* Add error reporting support with hot reloading.
* Update README.md