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
WeichienHung
a2bea9b492
Add mutation example to with-typescript-graphql ( #16742 )
...
Fixes https://github.com/vercel/next.js/issues/16550
Add a graphql mutation operation in this example.
The changes are:
1. Define mutation in schema `type-defs.graphqls`
2. Add mutation to `viewer.graphql ` that compiled to typescript code.
3. Add mutation resolver in `resolvers.ts`
4. [UI] add a input box and button to submit mutation request to change name.
screenshot of change
![mutation_example](https://user-images.githubusercontent.com/1462027/91797123-5ffc4e00-ec54-11ea-910b-3ddb399b42f0.gif )
2020-11-10 21:10:54 +00:00
Quinn Turner
6d4395f22c
fix: Order moduleFileExtensions
left-to-right ( #18328 )
...
Order moduleFileExtensions from most used to least used extensions.
Sources: https://jestjs.io/docs/en/configuration#modulefileextensions-arraystring
and facebook/jest#7616
2020-10-27 20:20:03 +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
Soichi Takamura
04c990678e
Update with-typescript-graphql ( #16101 )
2020-08-29 22:15:50 -04: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
Luis Alvarez D
43271821f2
[Examples] Move with-typescript-graphql to SSG ( #13854 )
...
Related to https://github.com/vercel/next.js/issues/11014
2020-06-10 04:14:53 +00: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
Joe Haddad
dbad9db68c
Update Examples for Fast Refresh ( #13068 )
2020-05-18 17:44:18 -04:00
Joe Haddad
86160a5190
Upgrade to Prettier 2 ( #13061 )
2020-05-18 15:24:37 -04:00
Soichi Takamura
790800305b
[examples/with-typescript-graphql] Add "createResolverContext" hook, etc. ( #11681 )
...
* Update deps
* Run "node-check-update -u"
* "graphql" keeps ^14 since other libs expect it
* Install apollo-link and apollo-cache because @apollo/react-common
wants it as peer-deps
* Add graphql-let/schema/loader
* This enables HMR from modifying *.graphqls.
* Add resolver context
* Remove JSDoc, respect TypeScript defs
* ncu -u
* Keep using graphql@^14.6.0 for the other deps
* fix: Migrate to graphql-let@0.10.0
* Removed duplicated deps
* Updated check
Co-authored-by: Luis Alvarez <luis@zeit.co>
2020-05-04 17:09:39 -05:00
dalibor-123
5808221f0d
gitignore graphql-let generated .d.ts files ( #12381 )
2020-05-02 00:48:28 -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
kkobiela
7227824b4a
Update dependencies ( #11707 )
2020-04-06 13:37:54 -05:00
Soichi Takamura
ccb42b0ed5
Update example "with-typescript-graphql" ( #10637 )
...
* add peerDeps of graphql-let
* ncu -u && typesync
* Use resolver types for resolver implementation
2020-02-25 01:44:09 -05: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
Soichi Takamura
f13bf1e2bf
[example with-typescript-graphql] Fix type error ( #10269 )
...
* fix: Type error
* Improve README.md
2020-01-25 22:32:58 -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
David Baumgold
72a898a7be
Correct spelling: withApollo ( #10055 )
2020-01-12 13:24:08 -05:00
Soichi Takamura
5fafd1a75b
Proposing a new example "with-typescript-graphql" ( #9803 )
...
* New example with-typescript-graphql
* Update newer graphql-let
* Apply @lfades 's suggestions
* Use "lib" for tools directory
* Move config decorator to next.config.js
* Apply stricter tsconfig
* mod: hide the word "apollo" from users
* mod: Use variable name `withApollo`
* Use the later version of graphql-let
* Only pages can be in pages
* Life improvements
* fix: .grpahql-let.yml point to the wrong document path
* Use a wider glob for less pitfalls
* Add a note about it in README.md
Co-authored-by: Luis Alvarez D. <luis@zeit.co>
2020-01-08 13:39:00 -05:00