1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
Commit graph

167 commits

Author SHA1 Message Date
Henrik 8bd46c8380 Remove .DS_Store file from helmet example (#1435) 2017-03-15 20:36:47 +01:00
Stephen Mathieson 8cf965a753 examples: add svg-components (#982) 2017-03-15 15:26:08 +01:00
BDav24 db7c286740 [POC] Pretty url routing (#1001)
* [example] with pretty url routing

* use single quotes even in React components

* improve Link import
2017-03-15 15:24:54 +01:00
Steve Fan a57fa7ebb1 An example with react-helmet (#1264)
* upload example

* fix

* fix

* fix

* fix .babelrc

* fix standard style

* fix indent

* rename helmetHead to helmet

* added gitignore

* package.json

* removed yarn.lock

* Added more examples of using react-helmet

* removed gitignore
2017-03-15 15:23:42 +01:00
Guilherme Diego 123a635f00 Example to create next application with scoped/external css. (#1340)
* First structure for external css example

* Remove: Builded files

* Fix: Identation to 2 spaces

* Fix example

* Fix lint

* Fix: Review points
2017-03-15 15:21:48 +01:00
Tim Neutkens 228bbbef74 Use jsonPageRes instead of xhr (#1424) 2017-03-15 08:07:29 +05:30
Adam Soffer d5bd8c7d03 Update with-apollo example (#1394)
* Add minimal apollo example

* Update apollo example README

* Update apollo example demo link in README

* Fix button styles

* Fix show more button

* Alias demo url

* Include the data field on the Apollo store when hydrating

* Revert

* Include the data field on the Apollo store when hydrating per tpreusse's suggestion.

* Add example to faq section in README

* Sort by newest; Add active state to buttons

* Make optimization suggestions

* Use process.browser; inline props

* Pass wrapped component's initial props into component heirarchy if they exist

* Remove unnecessary sorting of array

* Update Apollo example

* Remove trailing comma

* Update reduxRootKey

* Remove unnecessary babelrc

* Update with-apollo example

- Remove use of deprecated 'reduxRootKey' option
- Add loading indicator inside pagination button
2017-03-14 23:41:55 +01:00
Tim Neutkens 68a7b59b19 Upgrade styled-components. Fixes #1416 (#1422) 2017-03-14 13:18:10 -07:00
Luke Edwards 4ad5e2e0dc Examples: Update Inferno & Preact (#1407)
* clean & bump inferno & preact pkgs

* reenable UglifyJS for preact
2017-03-13 22:05:04 +01:00
Jayden Seric 02e697cb0d Updated with-apollo example. (#1389)
- Deleted several unused dependencies.
- Updated dependencies.
- Simplified Apollo related imports thanks to react-apollo exporting apollo-client and graphql-tag since [v0.13.2](https://github.com/apollographql/react-apollo/blob/master/Changelog.md#0132).
- Tidied the readme and added a link to the Apollo docs.
2017-03-12 08:33:01 +01:00
Sergio Daniel Xalambrí 38822717a9 Add support for URL objects in Link and Router (#1345)
* Add support for URL objects in Link and Router

* Fix typo in comment

* Fix possible bug if the `href` prop is `null`

* Document the usage of URL objects in Link and Router

* Update readme.md

* Parse URL to get the host & hostname in `isLocal`

This should check if the current location and the checked URL have the same `host` or `hostname`.

* Format `as` parameter from object to string if required

* Format `href` and `as` inside the construct and componentWillReceiveProps

* Use `JSON.stringify` to compare objects

* Add usage example

* chore(package): update chromedriver to version 2.28.0 (#1386)

https://greenkeeper.io/

* Refactor the codebase a bit.

* Change the example name.

* Add a few test cases.

* Add the example to the README.
2017-03-12 09:27:51 +05:30
Larry Lu 4fb7e4bc64 Fix typo (#1380)
port 300 -> 3000
2017-03-10 09:10:44 +01:00
Sergio Daniel Xalambrí bb3ceaadea Fix styled-components server-render example (#1382) 2017-03-10 09:07:28 +01:00
Tim Suchanek 40573317f7 Update README.md (#1368)
Fix graph.cool link in example
2017-03-07 14:47:31 +01:00
Tim Neutkens bf9d34df37 Disable uglify the pretty way (#1351) 2017-03-06 08:53:00 -08:00
Arunoda Susiripala f8f3fa7dce Introducing Shallow Routing (#1357)
* Simplify route info handling.

* Add basic resolve=false support.

* Make sure to render getInitialProps always if it's the first render.

* Change resolve=false to shallow routing.

* Add test cases for shallow routing.

* Update README for shallow routing docs.

* Update docs.

* Update docs.

* Update docs.
2017-03-06 08:48:35 -08:00
Conor Dockry 193eaf4c9e Add missing ! in using-preact example (#1355) (#1356) 2017-03-06 10:46:02 +05:30
Orlin M Bozhinov 563856f477 postcss-loader, postcss-easy-import, normalize.css and autoprefixer (#1352) 2017-03-05 07:48:37 -08:00
Tim Neutkens 5947716ff7 Implement preact/inferno SSR (#1346)
* Use module-alias to alias preact server side

* Use module-alias to alias inferno server side

* Remove unneeded routes example
2017-03-04 17:47:56 -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
Arana Jhonny bc47aac8f4 Fixed some problems with standard (#1331) 2017-03-02 22:46:16 +01:00
Orlin M Bozhinov 38cc82d0bc With global stylesheet paths (#1327)
* with-global-stylesheet without relative paths and with node_modules

* a parenthetical remark about material-components-web not being part of the example
2017-03-02 08:37:58 -08:00
fridays 7c8cd4bc69 Example with next-routes (#1290)
* Example with next-routes

* optimize description

* rename to with-next-routes
2017-03-01 09:42:47 -08:00
Arana Jhonny 68d48cb004 Update Koa example for Koa 2 with async/await (#1317) 2017-02-28 21:49:58 +01:00
Tim Neutkens e1babdfe9d Render styled-jsx in _document example (#1287) 2017-02-28 05:15:49 +05:30
Tim Neutkens f8f90955c5 Add prefetch to propTypes + flow typings (#1295) 2017-02-27 10:50:28 +05:30
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
Sébastien Dubois 6ede206d82 update link prefetch syntax in examples (#1276) 2017-02-25 15:54:42 +01:00
Eric Ferraiuolo e24db68f8b Add example app with React Intl (#1055)
* Add example app with React Intl

Fixes #1022

* Update examples/with-react-intl/package.json to be consistent
2017-02-24 22:45:18 +01:00
Tim Neutkens 9ba7a10f85 Fix linting errors (#1235) 2017-02-21 21:52:44 +01:00
Fabien Le Frapper 22c22efc35 Fix missing dependencies (#1232)
Tried to pull & run this example, it failed, complaining about missing react & react-dom dependencies
2017-02-21 16:40:18 +01:00
Davide Bertola d4b018e91f add ‘with-refnux’ example (#1215) 2017-02-20 20:13:05 -08:00
Tim Neutkens e5844314e3 Fix linting errors (#1197) 2017-02-18 20:12:19 +01:00
胡子大哈 bdd5b9ef3d Add note for next-connect-redux #1193 (#1203) 2017-02-18 19:39:34 +01:00
Guillermo Rauch 47e5231cdd Revert "Use the original idea of provider wrapper for redux example (#1201)"
This reverts commit ba54c6ac3d.
2017-02-18 14:11:54 -03:00
胡子大哈 ba54c6ac3d Use the original idea of provider wrapper for redux example (#1201)
Use the original idea of provider wrapper from #1193 and remove
unnecessary `initStore` in every page.
2017-02-18 14:03:02 -03:00
Kirill Konshin f0cb5b71a0 Added next-redux-wrapper to example (#1196)
* Added next-redux-wrapper to example

* Docs, renamed withRedux
2017-02-18 01:10:27 -03:00
Tim Neutkens 00590d7181 Remove babelrc for preact example (#1194) 2017-02-17 20:03:02 -03:00
Thomas Lindstrøm 6e5d57dae9 Add example with-scoped-stylesheets-and-postcss (#1146)
* Add example `with-external-stylesheets-and-postcss`

* 🔥 Remove extra semi-colon

* 📝 Attribute `with-global-stylesheet`

* Force a new test

* 📝 Update README.md

* Rename `external` -> `scoped`
2017-02-17 16:04:58 +01:00
Dan Zajdband e33a7dbc25 Now that we have react-dom as a peerDependency this import issue was fixed (#1183) 2017-02-16 19:44:43 -03:00
Tim Neutkens ff547752f0 Fix HMR issue with webpack-stats-analyzer (#1149)
* Use stats.json instead of running server

* Add suggested changes
2017-02-15 21:42:48 +09:00
Giuseppe db97fbffad Fix with-styled-jsx-postcss example (#1147) 2017-02-15 11:57:15 +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
Sébastien Dubois 3c7237169f ssr-caching: document way to configure cache key (#1133)
* ssr-caching: document way to configure cache key

* simplify comment
2017-02-14 22:01:50 +05:30
Tim Neutkens 2f7cc9c33c Add webpack-bundle-analyzer example (#1110) 2017-02-14 07:54:50 +05:30
sfhardman dbc2ceefde Return a promise from getRequestHandler execution, await _serveStatic in serveStaticWithGzip, update custom-server-hapi to complete request lifecycle (#1099) 2017-02-12 23:12:32 -03:00
Arunoda Susiripala b220193167 Babelrc false babelrc (#1094)
* Detect babelrc disabling via babelrc.

* Simplify boolean condition.
2017-02-13 06:18:22 +09:00
Davide Bertola 19f1125520 add global stylesheet example (#1016)
* add global stylesheet example

* fix avoiding html-escape of stylesheets

* update readme

* remove .gitignore
2017-02-12 00:22:35 +01:00
Tim Neutkens c106a1d02f Using router example improvements (#1034) 2017-02-09 22:02:01 +05:30
Arunoda Susiripala 57b6e9a71b Using styled-jsx for with-jest example. (#1052) 2017-02-09 19:14:52 +05:30