Steven
4466ba436b
chore(examples): use default prettier for examples/templates ( #60530 )
...
## Description
This PR ensures that the default prettier config is used for examples
and templates.
This config is compatible with `prettier@3` as well (upgrading prettier
is bigger change that can be a future PR).
## Changes
- Updated `.prettierrc.json` in root with `"trailingComma": "es5"` (will
be needed upgrading to prettier@3)
- Added `examples/.prettierrc.json` with default config (this will
change every example)
- Added `packages/create-next-app/templates/.prettierrc.json` with
default config (this will change every template)
## Related
- Fixes #54402
- Closes #54409
2024-01-11 16:01:44 -07:00
Horacio Valencia
081b8fba67
Updates Apollo Server Examples to use Apollo Server 4 & @as-integrations/next ( #42771 )
...
Closes https://github.com/vercel/next.js/issues/42769
## Description
This PR address https://github.com/vercel/next.js/issues/42769 by updating the `api-routes-apollo-server`, `api-routes-apollo-server-and-client` and `api-routes-apollo-server-and-client-auth` examples to use Apollo Server 4 and [@as-integrations/next](https://github.com/apollo-server-integrations/apollo-server-integration-next ), which is the Apollo Server Next integration package. The PR also updates the three examples to use Typescript. The functionality of the examples is the same.
## Documentation / Examples
- [X] Make sure the linting passes by running `pnpm build && pnpm lint`
- [X] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md )
closes https://github.com/vercel/next.js/pull/33545
closes https://github.com/vercel/next.js/pull/30082
closes https://github.com/vercel/next.js/issues/21984
closes #10413
2022-11-14 12:13:31 +00:00
Herman
25a4c00559
[EXAMPLES] fix apollo client cache hydration ( #27799 )
...
Current implementation causes bugs when navigating between SSG,SSR and
Client Side pages as cache gets overwritten.
Reusing more appropriate implementation used in example
api-routes-apollo-server-and-client-auth introduced with commit
4bbdd09097
2022-05-22 21:47:25 -05:00
David Stotijn
48621b3c7e
Update to 3.0 in api-routes-apollo-server-and-client example ( #15270 )
2020-07-17 16:25:41 -04:00
Luis Alvarez D
b4ec992815
[Examples] Move with-graphql-hooks to SSG ( #13858 )
...
Related to https://github.com/vercel/next.js/issues/11014
The setup is very similar to the one used for Apollo examples.
@Joezo I've removed the demo example that you added to the readme (https://github.com/vercel/next.js/pull/6482 ) as it will be outdated after this PR is merged.
2020-06-08 16:23:34 +00:00
Luis Alvarez D
792a113d48
[Examples] Move api-routes-apollo-server-and-client to SSG ( #13782 )
...
Ref: https://github.com/vercel/next.js/pull/13742
2020-06-06 13:04:52 +00:00
Joe Haddad
b7e17e09e5
Update references to zeit/next.js ( #13463 )
2020-05-27 17:51:11 -04:00
Joe Haddad
86160a5190
Upgrade to Prettier 2 ( #13061 )
2020-05-18 15:24:37 -04:00
Luis Alvarez D
fbcc0e818e
😌 ( #9923 )
2020-01-03 12:34:20 -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
Henrik Wenz
ba246446ef
Remove useMemo from apollo examples ( #8815 )
...
We don’t need useMemo here since its functionality is already covered by initApolloClient.
Thanks to @mpoisot
closes #8810
2019-09-21 13:17:21 +02:00
Henrik Wenz
1045cd4c5a
Refactor api-routes-apollo-server-and-client example ( #8673 )
...
* Remove connectToDevTools in favour of better default
Disabled devtools in production
* Refactor api-routes-apollo-server-and-client example
2019-09-12 10:44:53 -05:00
Aaron Reisman
6c01bbd6df
Add Apollo Server and Client Example App ( #8195 )
...
* Add Apollo Server and Client Example
* Update Apollo Client to use previous example setup
2019-09-05 18:42:32 -05:00