Luis Alvarez D
e28fd50441
Include utm_source on example links to vercel.com ( #21305 )
2021-01-19 07:28:54 +00:00
Luc Leray
8eaabe2fb0
Fix deploy buttons URLs ( #20834 )
...
Fix all deploy button URLs in the Next.js repo to follow the following format:
```
https://vercel.com/new/git/external?repository-url=https://github.com/vercel/next.js/tree/canary/examples/ <EXAMPLE_NAME>&project-name=<EXAMPLE_NAME>&repository-name=<EXAMPLE_NAME>
```
The detailed docs for the Deploy Button can be found here: https://vercel.com/docs/more/deploy-button .
Also updates legacy Vercel import flow URLs (starting with vercel.com/import or with vercel.com/new/project), to use the new vercel.com/new URLs.
---
For example, for the `hello-world` example:
The URL is https://vercel.com/new/git/external?repository-url=https://github.com/vercel/next.js/tree/canary/examples/hello-world&project-name=hello-world&repository-name=hello-world
And the deploy button looks like this:
[![Deploy with Vercel](https://vercel.com/button )](https://vercel.com/new/git/external?repository-url=https://github.com/vercel/next.js/tree/canary/examples/hello-world&project-name=hello-world&repository-name=hello-world )
---
For reference, I used the following regexes to search for the incorrect URLs
```
\(https://vercel.com/import/git\?s=https://github.com/vercel/next.js/tree/canary/examples/(.*) \)
\(https://vercel.com/import/git\?c=1&s=https://github.com/vercel/next.js/tree/canary/examples/ ([^&]*)(.*)\)
\(https://vercel.com/import/project\?template=https://github.com/vercel/next.js/tree/canary/examples/(.*) \)
https://vercel.com/import/git
https://vercel.com/import/select-scope
https://vercel.com/import
https://vercel.com/new/project
```
2021-01-07 01:40:29 +00:00
Joe Haddad
f17d435166
Ensure all examples are MIT licensed ( #16691 )
2020-08-29 22:32:35 -04:00
NorbertLuszkiewicz
c03d4931de
Simplify example usage instructions ( #16678 )
...
Co-authored-by: Joe Haddad <joe.haddad@zeit.co>
2020-08-29 22:22:02 -04:00
Aubrey
7d8e0c512f
updated active-class-name example to also demo a [slug]
path ( #15924 )
...
updated example for [active-class-name](f00ad581a1/examples/active-class-name
) to also support a `[slug].js` page that matches on `as` instead of `href` (as `href` would be `/[slug]`)
> This does not demo `[..slug].js` as this requires possible custom code for determining the slug path part for the active classname. i.e. page tree active nodes. A possible other example or another PR on this example.
Has possible information for:
* https://github.com/vercel/next.js/issues/7410
2020-08-06 01:26:48 +00:00
Tanmay Laud
f00ad581a1
Added .gitignore to examples that are deployed to vercel ( #15127 )
...
Co-authored-by: Joe Haddad <joe.haddad@zeit.co>
2020-07-16 10:52:23 -04:00
Joe Haddad
7d038dfef1
Suggest npx
over npm init
( #13637 )
...
This updates old examples to the more universal `npx` command.
Fixes https://github.com/vercel/next.js/discussions/12103
2020-06-01 17:36:57 +00:00
Joe Haddad
b7e17e09e5
Update references to zeit/next.js ( #13463 )
2020-05-27 17:51:11 -04:00
JJ Kasper
1f6ce106ae
Update codeload and deploy links for org rename ( #13141 )
...
Co-authored-by: Joe Haddad <joe.haddad@zeit.co>
2020-05-27 14:11:39 -04:00
Henrik Wenz
b280c82a5e
[Examples] Fix active-class-name ( #12931 )
2020-05-15 12:44:46 -04:00
Tim Neutkens
483bd3ddda
Rename ZEIT to Vercel ( #12075 )
...
* Find/replace
* Update more URLs
* More rename
* Fix remaining examples
* More updates
* Update create-next-app
* Update remaining text
* Update
Co-authored-by: Shu Uesugi <shu@chibicode.com>
2020-04-21 11:47:12 +02:00
Shu Uesugi
c57cdbb31d
Rename zeit.co/new → zeit.co/import ( #10674 )
...
* Replace zeit.co/new → zeit.co/import
* Update deployment.md
2020-02-24 19:08:34 -05:00
Shu Uesugi
5f041447bc
Remove Now CLI reference from examples ( #10501 )
...
* Find/Replace "Deploy it to the cloud..."
* Find/Replace "Deploy it to the cloud..." (no colon)
* Find/Replace "Deploy it to the cloud..." for firebase
* Convert remaining ones
* Storybook deployment
* Update with-stripe-typescript
* Update contributing.md
* Remove `now`
* Update examples/with-stripe-typescript/README.md
Co-Authored-By: Luis Alvarez D. <luis@zeit.co>
2020-02-12 17:14:57 -05:00
Shu Uesugi
6804039e94
Make example READMEs more consistent ( #10124 )
...
* npx create → npm init
* Fix inconsistent instructions
* Update amp-first
* Update with-graphql-react
* with-firebase-cloud-messaging
* Update with-higher-order-component
* change create-next-app url
* Update create-next-app instruction
* Update instructions to use npm instead of npx
* Move "the idea behind the example" to top
* Rename
* Rename
* Update contributing.md with a README template
2020-01-16 23:23:56 +01:00
Luis Alvarez D
7edf0da0c4
Add the deploy button to compatible examples ( #9547 )
2019-11-27 11:40:58 -05:00
Joe Haddad
18a9c7e371
Improve linting rules to catch more errors ( #9374 )
...
* Update `packages/`
* Update examples
* Update tests
* Update bench
* Update top level files
* Fix build
* trigger
2019-11-10 19:24:53 -08:00
Martin Grubinger
81066a396c
Fix example active-class-anme: Add support for children of ActiveLink without a className. ( #9271 )
...
* Fix example active-class-anme: Add support for children of ActiveLink without a className.
* Update examples/active-class-name/components/ActiveLink.js
Co-Authored-By: Luis Alvarez D. <luis@zeit.co>
2019-10-31 14:05:12 -05:00
Luis Alvarez D
f10f3304fe
Replace the deprecated Create Next App URL ( #9032 )
2019-10-10 23:34:14 -04:00
Henrik Wenz
ce25f747e7
Refactor active-class-name example ( #8558 )
...
- use router hook instead of hoc
- simplify ActiveLink component
- add prop-types
- add function names
- use fragments instead of divs
2019-08-29 12:22:42 -04:00
Connor Davis
3fa04620e7
Remove Deploy To Now buttons ( #7126 )
...
* Remove Deploy To Now buttons
* Remove remaining buttons
2019-04-24 10:53:58 +02:00
Juan Olvera
7e12997af6
Test updater script on examples folder ( #5993 )
...
I wrote a [script](https://github.com/j0lv3r4/dependency-version-updater ) to update dependencies recursively in `package.json` files, e.g.:
```
$ node index.js --path="./examples" --dependencies="react=^16.7.0,react-dom=^16.7.0"
```
This PR contains the result against the examples folder.
2019-01-05 12:19:27 +01:00
Tim Neutkens
9c4eefcdbf
Add prettier for examples directory ( #5909 )
...
* Add prettier for examples directory
* Fix files
* Fix linting
* Add prettier script in case it has to be ran again
2018-12-17 17:34:32 +01:00
Michael Herold
5b3578e58f
#4751 - Explicitly mention install when cloning examples ( #4758 )
...
Preferably this installation wouldn't be necessary, but in lieu of a fix...
#4751
2018-07-11 23:56:15 +02:00
James Hegedus
f2e56609cd
Examples: stabalise README format and create-next-app usage ( #4009 )
...
* Examples: clarify language around Yarn create & npx
* add missing READMEs and create-next-app usage
* suggest people tag jthegedus in firebase related issues
* add yarn alt instructions
* cerebraljs example readme & fixes
2018-04-03 14:19:05 +02:00
James Hegedus
b1d8b839dd
Examples: use npx and yarn create to run create-next-app on examples ( #4002 )
...
* remove global npm install of create-next-app
* add npx to create-next-app command in examples
* add bash to shell snippets
* add yarn create to next-app command in examples
* fix READMEs named with lowercase
* change READMEs to use UPPERCASE
2018-03-14 09:09:46 +01:00
Brent Clark
24d862cd6b
Remove console.log derp ( #3810 )
...
* fix copy pasta issue
* remove console.log derp
* resolve merge conflicts
2018-02-15 11:02:33 +01:00
Brent Clark
a8d07af355
use null instead of empty string for coerced className ( #3771 )
2018-02-12 10:10:01 +01:00
Tim Neutkens
24c1ac6ca9
Use canary for all example downloads ( #3411 )
2017-12-06 18:12:42 -08:00
Fouad Matin
2528779394
examples: add create-next-app ( #3377 )
...
* examples: add create-next-app
* fix with-typescript readme
2017-12-02 20:30:17 -08:00
Tim Neutkens
c8059b9f12
Make sure linting passes
2017-10-31 08:58:00 +01:00
Remy Sharp
4c18678d54
Create example of activeClassLink using withRouter ( #3188 )
2017-10-30 15:24:31 +01:00