Skip to content

Commit 67e7556

Browse files
authored
fix: link for bundle size reduction docs (#10075)
1 parent 942c25d commit 67e7556

25 files changed

Lines changed: 41 additions & 1 deletion

File tree

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@graphql-codegen/gql-tag-operations': patch
3+
'@graphql-codegen/client-preset': patch
4+
---
5+
6+
Add note about enabling bundle size reduction for the generated `graphql` tag file.

dev-test/gql-tag-operations-masking/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n fragment TweetFragment on Tweet {\n id\n body\n ...TweetAuthorFragment\n }\n':

dev-test/gql-tag-operations-urql/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n query Foo {\n Tweets {\n id\n }\n }\n': types.FooDocument,

dev-test/gql-tag-operations/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n query Foo {\n Tweets {\n id\n }\n }\n': types.FooDocument,

dev-test/gql-tag-operations/graphql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n query Foo {\n Tweets {\n id\n }\n }\n': types.FooDocument,

examples/persisted-documents-string-mode/src/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import * as types from './graphql';
1010
* 3. It does not support dead code elimination, so it will add unused operations.
1111
*
1212
* Therefore it is highly recommended to use the babel or swc plugin for production.
13+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1314
*/
1415
const documents = {
1516
'\n query HelloQuery {\n hello\n }\n': types.HelloQueryDocument,

examples/persisted-documents/src/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n query HelloQuery {\n hello\n }\n': types.HelloQueryDocument,

examples/react/apollo-client-defer/src/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n fragment SlowFieldFragment on Query {\n slowField(waitFor: 5000)\n }\n': types.SlowFieldFragmentFragmentDoc,

examples/react/apollo-client-swc-plugin/src/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n query allFilmsWithVariablesQuery($first: Int!) {\n allFilms(first: $first) {\n edges {\n node {\n ...FilmItem\n }\n }\n }\n }\n':

examples/react/apollo-client/src/gql/gql.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
1111
* 3. It does not support dead code elimination, so it will add unused operations.
1212
*
1313
* Therefore it is highly recommended to use the babel or swc plugin for production.
14+
* Learn more about it here: https://the-guild.dev/graphql/codegen/plugins/presets/preset-client#reducing-bundle-size
1415
*/
1516
const documents = {
1617
'\n query allFilmsWithVariablesQuery($first: Int!) {\n allFilms(first: $first) {\n edges {\n node {\n ...FilmItem\n }\n }\n }\n }\n':

0 commit comments

Comments
 (0)