Commit graph

1319 commits

Author SHA1 Message Date
Paul van Dyk
19f41c60bc
Update postcss.config.js (#11366)
* Update postcss.config.js

Return empty array if the condition is not met to avoid a null/undefined PostCSS plugin.

* Update postcss.config.js

Fix array spread

* Update postcss.config.js

remove extra operator

* Fix linting

Co-authored-by: Tim Neutkens <timneutkens@me.com>
2020-04-06 12:06:06 +02:00
Fabian Mastenbroek
20f2b0b3b2
Add example for polyfilling DOMParser in Node (#10782)
This change updates the README of the `react-intl` example to show how to use
the FormattedHTMLMessage component from `react-intl` in Node environments when
using pre-v4 versions.
2020-04-06 12:03:10 +02:00
Nathan Sculli
fa39b311ec
A little bit of maintenance on the ReasonML examples (#11662)
* Add babel-types package

`next dev` was failing with:

```
Error: Cannot find module 'babel-types'
```

* Upgrade to the latest bs-platform

Also add the `babel-types` package to stop the `next dev` command from complaining.

* Remove extraneous babel-plugin-bucklescript dependency.

Seems the dependency has been deprecated, and it doesn't seem to be required
anyways.
2020-04-06 10:44:01 +02:00
Tal Ater
89b69865fb
Fix documentation link in Basic API routes example (#11671)
Link to description of API Routes in the main README of the repo is broken. Replaced with a link to the documentation.
2020-04-05 13:46:48 +02:00
Alejandro
d46a0aef0f
Integrate with-atlaskit (#11269)
* Add with-atlaskit

* Fix

* Fix

* Add babel
2020-04-05 13:27:49 +02:00
David Janda
d093dd5786
Updated with-shallow-routing to use getServerSideProps (#11585)
* Replaced getInitialProps with getServerSideProps

* Updated page and readme

* Removed unrequired props

* Mention getStaticProps too

Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-04-03 14:59:39 -05:00
noejon
d97ac9ff82
[fix:typo] - Fixing a typo in the typescript example (#11630) 2020-04-03 11:44:57 +02:00
David Janda
641976a471
Replace getInitialProps with getServerSideProps (#11586) 2020-04-02 16:36:18 -05:00
Matt Carlotta
5db180b221
Fix styled-components example README notes (#11548)
* Add notes to styled-components example README

* Adjust notes to styled-components example README

* Fix styled-components README notes

* Update README
2020-04-01 14:00:13 -05:00
James Mosier
7b546a92c8
Update hello-world example React version & name for CodeSandbox (#11550) 2020-04-01 15:56:38 +02:00
Matt Carlotta
a37ad0ae07
Add notes to styled-components example README (#11540)
* Add notes to styled-components example README

* Adjust notes to styled-components example README
2020-04-01 12:21:04 +02:00
Luis Alvarez D
1992e2a96e
Example/update unstated (#11534)
* Updated components and deps

* Updated readme
2020-04-01 11:36:02 +02:00
Hugo Morosini
226387694b
added "with-route-as-modal" example (#11473)
* added "with-route-as-modal" exemple

extra space missing in style.css

oops

linted

* Use Link and removed unrequired imports

Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-03-31 14:10:55 -05:00
Freddy Jimenez
f2315ffc8f
update auth0 example with getServerSideProps (#11051)
* example improved

* put user cache back

* .env.template is back

* .env.template sorting back

* Header component calls fixed

* Context API removed

* Context API related text removed from README

* put everything back but getServerSideProps

* client side code removed from GSSP

* Updated comments

Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-03-31 13:08:01 -05:00
chislee0708
a553768514
Typos fixed: overriden --> overridden and innaccurate -->inacc… (#11454) 2020-03-30 10:54:06 +02:00
Mateusz Burzyński
fc946053fd
Update emotion dependencies in with-emotion-11 (#11414) 2020-03-28 14:41:31 -05:00
Ren Adachi
41764b28dc
Update .gitignore (#11421)
add node_modules/
2020-03-28 14:35:20 -05:00
Jazib Jafri
9e2ae69973
Update api-rest-example to SSG (#11362)
* Update api-rest-example to SSG

* Use SWR for data fetching

* Updated pages

Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-03-28 13:27:17 -05:00
sdhani
48650a7d5d
Fix with-aphrodite readme typo (#11436) 2020-03-28 13:02:12 -05:00
MichelleLucero
2b818a1e8b
fixed typo: libraray -> library (#11435)
Co-authored-by: Michelle Lucero <31500626+mlucero4607@users.noreply.github.com>
2020-03-28 12:57:19 -05:00
Ben Goerdt
44b4070fe3
Revert "Fix assignment of props in WithApollo.getInitialProps (#11236)" (#11384)
This reverts commit db57ad3b30.
2020-03-26 18:21:38 -05:00
Jazib Jafri
e02b66a52c
Add with-redux-toolkit example (#11358) 2020-03-26 13:15:40 -05:00
Luis Alvarez D
044ddf4421
[Example] Use .jpg for images in blog-starter (#11176)
* Use .jpg for images

* Updated links
2020-03-26 12:45:17 -05:00
Luis Alvarez D
a391d328ae
Add docs for multi zones (#11348)
* Updated example

* Added single now.json

* Added Multi Zones docs

* Fix titles

* Added back the deploy button
2020-03-26 10:44:00 +01:00
Yuji Matsumoto
67fd72b764
Fix preview-mode docs/examples typo (#11345)
be know => be known
2020-03-25 18:13:33 +01:00
Rishabh Saxena
b46abed61b
use records to init store (#11343) 2020-03-25 12:03:52 -05:00
Nicolas Rouanne
ed0643486a
fix: typo in isStaging in with-env example (#11305)
* fix: typo in `isStaging` in `with-env` example

- add missing `phase ===` statement when checking for _staging_ env in `isStaging`

* Update examples/with-env-from-next-config-js/next.config.js

* style: fix prettier issue in example `with-env-from-next-config-js`

Co-authored-by: Luis Alvarez D <luis@zeit.co>
2020-03-24 10:16:47 +01:00
Ben Goerdt
db57ad3b30
Fix assignment of props in WithApollo.getInitialProps (#11236)
The props are being assigned incorrectly based on the `inAppContext`, they should be wrapped in `pageProps` when `inAppContext` is true, not the other way around. This will cause a new apollo client to be created during `getDataFromTree` instead of using the one that has already been created on the server.
2020-03-24 10:11:24 +01:00
Greg Rickaby
cadc950e2d
docs(example): Load basic-css example on codesandbox (#11227)
* Load basic-css example on codesandbox

* Moved link

Co-authored-by: Luis Alvarez <luis@zeit.co>
Co-authored-by: Shu Uesugi <shu@chibicode.com>
2020-03-20 15:39:36 -05:00
julianbenegas
f1944cad88
With Firebase Client-Side example (#11053)
* initialized example

* Import from "firebase/app"

to get only needed firebase modules

* credentials as env variables
Also, initialize app in a separate file. Much cleaner.

* Update examples/with-firebase-client-side/package.json

Co-Authored-By: Luis Alvarez D. <luis@zeit.co>

* fixed environment variables and added .env.example

* added dotenv

* Updated readme

* Renamed example in the readme

* Renamed example files

* Updated title

Co-authored-by: Luis Alvarez D. <luis@zeit.co>
2020-03-20 15:38:28 -05:00
Martín Granados García
8724b3cd2f
Updated Api Routes Middleware example to use getServerSideProps (#11128) 2020-03-20 12:47:37 -05:00
Avi Aryan
920bf76579
Fix with-firebase-cloud-messaging example setup code (#10686) 2020-03-20 10:15:45 +01:00
Timon Borter
c25447ccbb
update mocha example with yml configuration. (#11214) 2020-03-20 10:13:57 +01:00
Shu Uesugi
a63ac3e715
CMS TakeShape Example (#11038)
* TakeShape Example

* Fix preview logic

* Update README

* Fix broken link

* Be more clear with the relationship field

* Use latest next.js for cms examples

* Only show enabled items

* Ignore current slug

* Fix queries

* Add takeshape demo

* Added link to blog-starter

Co-authored-by: Luis Alvarez D <luis@zeit.co>
2020-03-19 17:30:37 -05:00
Luis Alvarez D
7d42b07b79
[Example] with-passport (#10529)
* Added basic layout with login page

* Updated styles

* Added form component

* Added signup page

* Added login/signup API endpoints

* Bug fixes

* Set the cookie

* Added logout route

* Added more auth

* Updated signup

* Added profile page

* Added useUser

* Fix link

* Updated redirect path

* Renaming some files

* Added README

* Apply suggestions from Shu

Co-Authored-By: Shu Uesugi <shu@chibicode.com>

* Add useUser to the header

Co-authored-by: Shu Uesugi <shu@chibicode.com>
2020-03-19 11:40:13 -05:00
JJ Kasper
756b365adf
Add CMS example for Sanity (#10907)
* Add start of Sanity CMS example

* Update cover-image

* Clean up example

* Apply suggestions from code review

Co-Authored-By: Shu Uesugi <shu@chibicode.com>

* Make changes from review

* Remove extra style

* Apply suggestions from code review

Co-Authored-By: Shu Uesugi <shu@chibicode.com>

* Make tweaks for preview mode and normalize env naming

* Update viewing preview step

* Delete author.jpg

* Delete image.jpg

* Update README

* Fix environment variable names

* Project ID is needed by lambda

* Improved steps

* Fixed issue with the project URL example

* Clarify line

* Get the preview post correctly

* preview = false

* Get unique posts

* Show preview mode on index page

* typo fix and use next latest

* Added related examples section

Co-authored-by: Shu Uesugi <shu@chibicode.com>
Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-03-18 18:39:37 -05:00
Shaswat Saxena
43c11904d3
Updated with-typescript example to SSG (#11081)
* Update with-typescript example to SSG

* Fixed usage of localhost inside SSG methods

Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-03-18 15:15:04 -05:00
Zhe Zhang
14efae931a
[Examples] fix remark link in blog-starter's README (#11177) 2020-03-18 17:36:04 +01:00
Tim Neutkens
1c170c946a
Remove react-ssr-prepass alias as it's not longer needed (#11170) 2020-03-18 13:47:28 +01:00
Tim Neutkens
ac34a9f960
Clean up examples directory (#11169)
* Remove outdated examples

* Remove outdated example

* Remove outdated example that doesn't show best practices

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Update preact example

* Update using-router to use useRouter

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Combine examples

* Simplify offered examples

* Remove outdated example

* Add link to new example

* Removed outdated example

* Markdown example has been improved

* Remove example that showed bad practices

* Remove outdated example

* Update polyfills example

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Removed outdated example

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Remove outdated example

* Update webassembly example

* Move example
2020-03-18 13:45:31 +01:00
Tim Neutkens
88a6bb36ba
Update blog-starter example (#11071)
* Update blog-starter example

* Updated content

* Updated readme

* Updated readme

* static → assets

* Add bottom margin

* Add to docs

* Add excerpt

* Update docs/advanced-features/preview-mode.md

Co-authored-by: Luis Alvarez <luis@zeit.co>
Co-authored-by: Shu Uesugi <shu@chibicode.com>
2020-03-18 09:43:09 +01:00
Tim Neutkens
7e2d476e44
Update examples to use getStaticProps where possible (#11136)
* Remove micro example

* Remove page that uses getInitialProps

* Update with-docker example

* Update dynamic import example

* Update Fela example

* Update Flow example

* Update framer motion example

* Remove freactal example

* Remove with-higher-order-component

* Remove with-immutable-redux-wrapper as it shows avenues to performance issues

* Remove example that doesn't have usage

* Update with-kea

* Remove example that is not used

* Update next-page-transitions example

* Remove next-routes example as dynamic routes are supported by default

* Add link to documentation

* Update Overmind example

* Update pretty-url-routing example

* Remove update with low usage

* Update with-react-ga example

* Update React Helmet example

* Remove mobile-detect from carousel example

* Remove react-useragent as it shows a bad practice

* Remove react-uwp example as it has low usage

* Remove recompose example as it shows outdated practices

* Remove refnux example as it has low usage

* Remove example that can be created using api routes

* Update with-segment-analytics

* Update socket.io example

* Remove socket.io example as it's shows bad practices

* Update static export example

* Update universal configuration example
2020-03-17 15:07:27 +01:00
Kenta Moriuchi
bfab9907b1
Move public directory for development in examples/with-firebas… (#11085) 2020-03-17 11:30:59 +01:00
Sangwon Lee
22e3b93913
Update with-react-multi-carousel example to use GSSP (#11069) 2020-03-17 11:28:59 +01:00
Carlos Pavanetti
bb3cce2315
Update ssr-caching example with getServerSideProps (#11032)
* Replace getInitialProps by getServerSideProps

* Replace getServerSideProps getStaticProps
2020-03-14 10:14:14 +01:00
Tom Dohnal
e6b4cdd665
update form handler example (#11059) 2020-03-13 16:57:12 -05:00
Jazib Jafri
31a6410bb2
Update with-loading example to SSG (#11050)
* Update getInitialProps to getStaticProps

* Updated example

Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-03-13 16:48:32 -05:00
Shu Uesugi
b596c2167d
Upgrade next.js version on datocms example (#11039)
* Remove unused files

* Update next

Co-authored-by: Joe Haddad <joe.haddad@zeit.co>
2020-03-13 15:03:29 -04:00
matamatanot
13bfb9a73d
Update custom-server-express example with getServerSideProps (#11035)
* use getServerSideProps

* run Prettier

* update react

* use getStaticProps

* delete query

* Remove data fetching requirements

Co-authored-by: “kosuke_matano” <kosuke_matano@cyberagent.co.jp>
Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-03-13 13:48:07 -05:00
Luis Alvarez D
7bf7c232ea
Use getServerSideProps (#11057) 2020-03-13 11:54:32 -05:00