Arunoda Susiripala
22776c2eee
Implement the Singleton Router API ( #429 )
...
* 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.
2016-12-19 06:40:26 -08:00
Naoyuki Kanezawa
1708222381
Programmatic API ( #310 )
...
* add 'next' api
* add render APIs
* add 'as' prop to Link
* check Accept header to serve json response
* check if response was finished on getInitialProps call
* move server/app to server/index
* load webpack-hot-middleware-client by absolute path
* server: options for testing
* add tests
* example: improve
* server: make dir optional
* fix client routing
* add parameterized routing example
* link: fix display url
* Add custom-server-express example (#352 )
* Add custom-server-express example
* Remove extraneous nexts in express routes defs
* Update next config in server.js
* Handle accept headers totally inside Next.js (#385 )
* Handle accept headers totally inside Next.js
Now user doesn't need to handle it anymore.
* Move json pages serving to /_next/pages base path.
* Join paths correctly.
* remove next/render
2016-12-16 12:33:08 -08:00
Naoyuki Kanezawa
c7ba914f52
Handle runtime errors ( #268 )
...
* display runtime errors by error-debug
* server: fix status
* render Error component on client error
* server: render runtime errors of error template
* server: handle errors of error template on render404
* server: add a comment
* server: refactor renderJSON
* recover from runtime errors
* _error: check if xhr exists
* _error: improve client error
* _error: improve error message
2016-11-24 23:03:16 +09:00
nkzawa
5383ad7ed9
fix getInitialProps doesn't get called when only url query was changed
2016-11-06 17:34:51 +09:00
nkzawa
efbf0efc98
fix query for getInitialProps is not parsed as an object
2016-11-06 15:09:37 +09:00
Naoyuki Kanezawa
d1a0309af9
Add pathname and query to the argument of getInitialProps ( #194 )
...
* pass pathname and query to getInitialProps on both server and client
* README: describe about the contet object of getInitialProps
2016-11-04 01:05:03 -07:00
David Street
7186fe8b7e
Only update history state if url differs. ( #172 )
2016-11-03 19:15:03 +09:00
nkzawa
7569ef6ca9
hot reload compilation errors
2016-10-25 00:20:50 +09:00
nkzawa
7ec46d512b
hot reload added/removed pages
2016-10-24 16:22:15 +09:00
nkzawa
2e2db37ccb
add error page for debug
2016-10-19 21:41:45 +09:00
nkzawa
3c44137b9b
improve hot-reloading
2016-10-17 23:35:31 +09:00
Dan Zajdband
1477734211
Added linting using standard ( #27 )
...
* Added linting using standard
* Linting on test
2016-10-16 17:00:17 -07:00
Dan Zajdband
7a331084dc
Reverting default props for errors. ( #12 )
2016-10-16 15:44:26 -07:00
Dan Zajdband
e527098bb9
Implemented missing pieces for overriding 404 and 500 pages. ( #10 )
2016-10-15 17:36:54 -05:00
nkzawa
a8c6b9e57a
lib/router: improve aborting xhr
2016-10-09 20:01:06 +09:00
nkzawa
6718b05347
add _error.js, fix error handlings
2016-10-09 18:25:38 +09:00
nkzawa
22bf51bbe0
support getInitialProps
2016-10-08 19:16:22 +09:00