apollographql / apollo-utils

Monorepo of common utilities related to Apollo and GraphQL
MIT License
36 stars 9 forks source link

chore(deps): update dependency @graphql-codegen/client-preset to v4.3.0 #448

Closed renovate[bot] closed 3 months ago

renovate[bot] commented 3 months ago

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@graphql-codegen/client-preset (source) 4.2.6 -> 4.3.0 age adoption passing confidence

Release Notes

dotansimha/graphql-code-generator (@​graphql-codegen/client-preset) ### [`v4.3.0`](https://togithub.com/dotansimha/graphql-code-generator/blob/HEAD/packages/presets/client/CHANGELOG.md#430) [Compare Source](https://togithub.com/dotansimha/graphql-code-generator/compare/@graphql-codegen/client-preset@4.2.6...@graphql-codegen/client-preset@4.3.0) ##### Minor Changes - [#​10001](https://togithub.com/dotansimha/graphql-code-generator/pull/10001) [`1be6e65`](https://togithub.com/dotansimha/graphql-code-generator/commit/1be6e65943b85162f3d465189d0a6df4b962df5d) Thanks [@​n1ru4l](https://togithub.com/n1ru4l)! - Support discriminating `null` and `undefined` within the `useFragment` function. ```ts function MyComponent(props: FragmentType | null) { const data = useFragment(MyFragment, props); // data is `MyFragment | null` } function MyComponent(props: FragmentType | undefined) { const data = useFragment(MyFragment, props); // data is `MyFragment | undefined` } ``` Before, the returned type from `useFragment` was always `TType | null | undefined`. - [#​9804](https://togithub.com/dotansimha/graphql-code-generator/pull/9804) [`5e594ef`](https://togithub.com/dotansimha/graphql-code-generator/commit/5e594ef8f39b9e1036b6bcaa977f914a66fec03e) Thanks [@​rachel-church](https://togithub.com/rachel-church)! - Preserving `Array` or `ReadonlyArray` in `useFragment()` return type. ##### Patch Changes - [#​9996](https://togithub.com/dotansimha/graphql-code-generator/pull/9996) [`99f449c`](https://togithub.com/dotansimha/graphql-code-generator/commit/99f449c8dcd645d49eda26e4ddfcb8ad7056ecbf) Thanks [@​nahn20](https://togithub.com/nahn20)! - Added configuration to allow for custom hash functions for persisted documents in the client preset ##### Example ```ts filename="codegen.ts" {10-12} import { type CodegenConfig } from '@​graphql-codegen/cli'; const config: CodegenConfig = { schema: 'schema.graphql', documents: ['src/**/*.tsx'], generates: { './src/gql/': { preset: 'client', presetConfig: { persistedDocuments: { hashAlgorithm: operation => { const shasum = crypto.createHash('sha512'); shasum.update(operation); return shasum.digest('hex'); }, }, }, }, }, }; ``` - Updated dependencies \[[`5501c62`](https://togithub.com/dotansimha/graphql-code-generator/commit/5501c621f19eb5ef8e703a21f7367e07e41f199c)]: - [@​graphql-codegen/add](https://togithub.com/graphql-codegen/add)[@​5](https://togithub.com/5).0.3

Configuration

📅 Schedule: Branch creation - "every weekend" in timezone America/Los_Angeles, Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.



This PR has been generated by Mend Renovate. View repository job log here.

changeset-bot[bot] commented 3 months ago

⚠️ No Changeset found

Latest commit: 17a5535dad7ab359faa3b557186fc618f56df7fe

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

codesandbox-ci[bot] commented 3 months ago

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.