Skip to content

Commit

Permalink
Merge branch 'master' into document_transform
Browse files Browse the repository at this point in the history
  • Loading branch information
kazekyo committed Feb 18, 2023
2 parents 483d1e5 + 209f2fc commit 6f57c11
Show file tree
Hide file tree
Showing 439 changed files with 12,286 additions and 79,618 deletions.
5 changes: 5 additions & 0 deletions .changeset/@graphql-codegen_add-8879-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/add": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-codegen_cli-9000-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/cli": patch
---
dependencies updates:
- Updated dependency [`@whatwg-node/fetch@^0.8.0` ↗︎](https://www.npmjs.com/package/@whatwg-node/fetch/v/0.8.0) (from `^0.6.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/client-preset": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-codegen_core-8879-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/core": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/fragment-matcher": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/gql-tag-operations": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/gql-tag-operations-preset": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/graphql-modules-preset": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/introspection": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/plugin-helpers": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-codegen_schema-ast-8879-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/schema-ast": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-codegen_testing-8879-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/testing": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/typed-document-node": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
5 changes: 5 additions & 0 deletions .changeset/@graphql-codegen_typescript-8879-dependencies.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/typescript": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/typescript-document-nodes": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/typescript-operations": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/typescript-resolvers": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@graphql-codegen/visitor-plugin-common": patch
---
dependencies updates:
- Updated dependency [`tslib@~2.5.0` ↗︎](https://www.npmjs.com/package/tslib/v/2.5.0) (from `~2.4.0`, in `dependencies`)
7 changes: 7 additions & 0 deletions .changeset/bright-islands-pretend.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'@graphql-codegen/cli': minor
'@graphql-codegen/client-preset': minor
'@graphql-codegen/gql-tag-operations-preset': minor
---

It is no longer mandatory to declare an empty plugins array when using a preset
5 changes: 5 additions & 0 deletions .changeset/chilly-beers-sleep.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@graphql-codegen/plugin-helpers': minor
---

mark `plugins` in config optional
6 changes: 6 additions & 0 deletions .changeset/nasty-eggs-rule.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@graphql-codegen/gql-tag-operations': patch
'@graphql-codegen/client-preset': patch
---

Use `gqlTagName` for generated examples
5 changes: 5 additions & 0 deletions .changeset/popular-radios-shake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@graphql-codegen/typescript-resolvers': minor
---

Updated customResolveInfo to use the correct importType for external imports
5 changes: 5 additions & 0 deletions .changeset/rare-rats-rhyme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@graphql-codegen/visitor-plugin-common': patch
---

Always inline referenced fragments within their document. This prevents issues with duplicated fragments or missing fragments.
6 changes: 6 additions & 0 deletions .changeset/rotten-lizards-bathe.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@graphql-codegen/client-preset': patch
'@graphql-codegen/typed-document-node': patch
---

Allow passing fragment documents to APIs like Apollos `readFragment`
2 changes: 1 addition & 1 deletion .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@ module.exports = {
},
},
],
ignorePatterns: ['dev-test', 'examples/front-end', 'website'],
ignorePatterns: ['dev-test', 'examples/front-end', 'website', 'examples/**/gql/**', '**/react-app-env.d.ts'],
};
32 changes: 28 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ jobs:
- name: Setup env
uses: the-guild-org/shared-config/setup@main
with:
nodeVersion: 17
nodeVersion: 16
- name: Prettier Check
run: yarn prettier:check
dev-tests:
dev-tests-old:
name: Validating dev-tests
runs-on: ubuntu-latest
strategy:
Expand All @@ -45,7 +45,7 @@ jobs:
- name: Setup env
uses: the-guild-org/shared-config/setup@main
with:
nodeVersion: 17
nodeVersion: 16
- name: Build
run: yarn build
env:
Expand All @@ -54,6 +54,30 @@ jobs:
run: |
yarn run generate:examples:${{matrix.method}}
git diff --exit-code -- dev-test/
dev-tests:
name: Examples
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup env
uses: the-guild-org/shared-config/setup@main
with:
nodeVersion: 16
- name: Build
run: yarn build
env:
CI: true
- name: Generate and Diff Codegen Artifacts
run: |
yarn examples:codegen
git diff --exit-code -- examples/
- name: Build Examples
run: |
yarn examples:build
- name: End2End Test Examples
run: |
yarn examples:test:end2end
esm:
name: Testing exports integrity
runs-on: ubuntu-latest
Expand All @@ -63,7 +87,7 @@ jobs:
- name: Setup env
uses: the-guild-org/shared-config/setup@main
with:
nodeVersion: 17
nodeVersion: 16
- name: Build
run: yarn build
env:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,6 @@ out/
website/public/sitemap.xml
website/public/_redirects
.eslintcache

**/cypress/screenshots
**/cypress/videos
7 changes: 5 additions & 2 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@ website/src/pages/docs/guides/react.mdx
website/src/pages/plugins/index.mdx
website/src/pages/plugins/presets/near-operation-file-preset.mdx

examples/**/gql/**

website/algolia-lockfile.json
temp/
website/out
website/.next

# added because it blocks CI and when I try to format it locally nothing happens :)
website/src/components/live-demo/LiveDemo.tsx
5 changes: 0 additions & 5 deletions dev-test/codegen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,34 +189,29 @@ const config: CodegenConfig = {
schema: './dev-test/gql-tag-operations/schema.graphql',
documents: './dev-test/gql-tag-operations/src/**/*.ts',
preset: 'gql-tag-operations-preset',
plugins: [],
},
'./dev-test/gql-tag-operations/graphql/': {
schema: './dev-test/gql-tag-operations/schema.graphql',
documents: './dev-test/gql-tag-operations/src/**/*.ts',
preset: 'client',
plugins: [],
},
'./dev-test/gql-tag-operations-urql/gql': {
schema: './dev-test/gql-tag-operations-urql/schema.graphql',
documents: './dev-test/gql-tag-operations-urql/src/**/*.ts',
preset: 'gql-tag-operations-preset',
presetConfig: { augmentedModuleName: '@urql/core' },
plugins: [],
},
'./dev-test/gql-tag-operations-masking/gql': {
schema: './dev-test/gql-tag-operations-masking/schema.graphql',
documents: './dev-test/gql-tag-operations-masking/src/**/*.tsx',
preset: 'gql-tag-operations-preset',
presetConfig: { fragmentMasking: true },
plugins: [],
},
'./dev-test/gql-tag-operations-masking-star-wars/gql': {
schema: './dev-test/gql-tag-operations-masking-star-wars/schema.json',
documents: './dev-test/gql-tag-operations-masking-star-wars/src/**/*.tsx',
preset: 'gql-tag-operations-preset',
presetConfig: { fragmentMasking: true },
plugins: [],
},
},
};
Expand Down
Loading

0 comments on commit 6f57c11

Please sign in to comment.