@graphql-codegen/cli@8.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! -generate()now returns
Promise<FileOutput[] | void>instead ofPromise<FileOutput[] | any>. The result is no longer
any, so consumers using the result as an array must narrow it first.Refs #11071
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the deprecated
emitLegacyCommonJSImportsconfig option and the--emit-legacy-common-js-importsCLI flagUse
importExtension(or--import-extension) to set the extension appended to relative imports.
WhenimportExtensionis not set, no extension is appended.@graphql-codegen/plugin-helpersno longer exportsnormalizeImportExtension. Use
importExtension ?? ''instead.Migration:
const config: CodegenConfig = { - emitLegacyCommonJSImports: false, + importExtension: '.js', }; -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE -config.generatesno
longer takesConfiguredPlugin[], takesConfiguredOutput[]insteadconfig.generates's previous typing allowed a value to be an array e.g.generates: { "src/gql/generated.ts": [{ typescript: {} }] }However, this never worked because this config is eventually passed into
normalizeOutputParam
which previously had this bug in the implementation:export function normalizeOutputParam(config) { // 0. When config is an array... if (isOutputConfigArray(config)) { // 1. `isOutputConfigArray(config)` was `Array.isArray(config)` -> returns true return { documents: [], schema: [], plugins: isConfiguredOutput(config) ? config.plugins : config // 2. ‼️ `isConfiguredOutput(config)` was `typeof config === 'object'` -> returns true. This is a bug because we are accessing `plugins` property of an array, which will ALWAYS be `undefined` -> the output is always rejected as "Invalid Codegen Configuration" } } if (isConfiguredOutput(config)) { return config } throw new Error(`Invalid "generates" config!`) }
Now, an array is still accepted, but as
ConfiguredOutput[]instead. For this major version
release, only the first array element is used, and@graphql-codegen/clilogs a warning when
there is more than one element.normalizeOutputParamnow returnsConfiguredOutput[]instead of a singleConfiguredOutput.@graphql-codegen/clialso throws its "Invalid Codegen Configuration" error when agenerates
array is empty or its first element is not a config object. This error is now a single generic
message, no longer naming the output file, and it shows a TypeScriptCodegenConfigexample with
theConfiguredOutputshape instead of the old YAML plugin-list example.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/apollo-engine-loader@^9.0.2↗︎
(from^8.0.38, independencies) - Updated dependency
@graphql-tools/code-file-loader@^9.0.3↗︎
(from^8.1.41, independencies) - Updated dependency
@graphql-tools/git-loader@^9.0.3↗︎
(from^8.0.44, independencies) - Updated dependency
@graphql-tools/github-loader@^10.0.3↗︎
(from^9.1.11, independencies) - Updated dependency
@graphql-tools/graphql-file-loader@^9.0.2↗︎
(from^8.1.22, independencies) - Updated dependency
@graphql-tools/json-file-loader@^9.0.2↗︎
(from^8.0.36, independencies) - Updated dependency
@graphql-tools/load@^9.0.2↗︎
(from^8.1.19, independencies) - Updated dependency
@graphql-tools/merge@^10.0.2↗︎
(from^9.2.6, independencies) - Updated dependency
@graphql-tools/url-loader@^10.0.2↗︎
(from^9.1.12, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql-config@^6.0.0↗︎ (from
^5.1.8, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/apollo-engine-loader@^9.0.2↗︎
(from^8.0.38, independencies) - Updated dependency
@graphql-tools/code-file-loader@^9.0.3↗︎
(from^8.1.41, independencies) - Updated dependency
@graphql-tools/git-loader@^9.0.3↗︎
(from^8.0.44, independencies) - Updated dependency
@graphql-tools/github-loader@^10.0.3↗︎
(from^9.1.11, independencies) - Updated dependency
@graphql-tools/graphql-file-loader@^9.0.2↗︎
(from^8.1.22, independencies) - Updated dependency
@graphql-tools/json-file-loader@^9.0.2↗︎
(from^8.0.36, independencies) - Updated dependency
@graphql-tools/load@^9.0.2↗︎
(from^8.1.19, independencies) - Updated dependency
@graphql-tools/merge@^10.0.2↗︎
(from^9.2.6, independencies) - Updated dependency
@graphql-tools/url-loader@^10.0.2↗︎
(from^9.1.12, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql-config@^6.0.0↗︎ (from
^5.1.8, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql-config@^6.0.0↗︎ (from
^5.1.8, independencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
7366c63,
fa49a37,
fa49a37]:- @graphql-codegen/client-preset@7.0.0
- @graphql-codegen/core@7.0.0
- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/core@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: A plugin'svalidate
function now receives an info object as its fourth argument, matching thepluginfunction:
validate(schema, documents, config, { outputFile, allPlugins, pluginContext }). Custom plugins
that exportvalidateand readoutputFile,allPluginsorpluginContextas positional
arguments must destructure them from the fourth argument instead.Refs #11071
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/schema@^11.0.2↗︎
(from^10.1.3, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/schema@^11.0.2↗︎
(from^10.1.3, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/add@8.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/fragment-matcher@8.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: A plugin'svalidate
function now receives an info object as its fourth argument, matching thepluginfunction:
validate(schema, documents, config, { outputFile, allPlugins, pluginContext }). Custom plugins
that exportvalidateand readoutputFile,allPluginsorpluginContextas positional
arguments must destructure them from the fourth argument instead.Refs #11071
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/introspection@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: A plugin'svalidate
function now receives an info object as its fourth argument, matching thepluginfunction:
validate(schema, documents, config, { outputFile, allPlugins, pluginContext }). Custom plugins
that exportvalidateand readoutputFile,allPluginsorpluginContextas positional
arguments must destructure them from the fourth argument instead.Refs #11071
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/schema-ast@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: A plugin'svalidate
function now receives an info object as its fourth argument, matching thepluginfunction:
validate(schema, documents, config, { outputFile, allPlugins, pluginContext }). Custom plugins
that exportvalidateand readoutputFile,allPluginsorpluginContextas positional
arguments must destructure them from the fourth argument instead.Refs #11071
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the
commentDescriptionsoption fromSchemaASTConfig. It has had no effect since graphql 16, which
no longer prints descriptions as comments. Delete it from yourschema-astconfig; the generated
output does not change. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Removed dependency
@graphql-tools/utils@^12.0.3↗︎
(fromdependencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Removed dependency
-
#11075
fa49a37
Thanks @eddeee888! - Remove unused@graphql-tools/utils
dependency -
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/time@8.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/visitor-plugin-common@8.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the deprecated
emitLegacyCommonJSImportsconfig option and the--emit-legacy-common-js-importsCLI flagUse
importExtension(or--import-extension) to set the extension appended to relative imports.
WhenimportExtensionis not set, no extension is appended.@graphql-codegen/plugin-helpersno longer exportsnormalizeImportExtension. Use
importExtension ?? ''instead.Migration:
const config: CodegenConfig = { - emitLegacyCommonJSImports: false, + importExtension: '.js', }; -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }.
Minor Changes
-
#11103
409ffbf
Thanks @jerelmiller! - Add support for graphql v17 fragment
arguments (experimentalFragmentArguments).To use fragment arguments, set the parser option in the root
config:const config: CodegenConfig = { config: { experimentalFragmentArguments: true } // ... }
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/optimize@^3.0.0↗︎
(from^2.0.0, independencies) - Updated dependency
@graphql-tools/relay-operation-optimizer@^8.0.2↗︎
(from^7.1.12, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/optimize@^3.0.0↗︎
(from^2.0.0, independencies) - Updated dependency
@graphql-tools/relay-operation-optimizer@^8.0.2↗︎
(from^7.1.12, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/typescript-document-nodes@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: A plugin'svalidate
function now receives an info object as its fourth argument, matching thepluginfunction:
validate(schema, documents, config, { outputFile, allPlugins, pluginContext }). Custom plugins
that exportvalidateand readoutputFile,allPluginsorpluginContextas positional
arguments must destructure them from the fourth argument instead.Refs #11071
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/gql-tag-operations@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the deprecated
emitLegacyCommonJSImportsconfig option and the--emit-legacy-common-js-importsCLI flagUse
importExtension(or--import-extension) to set the extension appended to relative imports.
WhenimportExtensionis not set, no extension is appended.@graphql-codegen/plugin-helpersno longer exportsnormalizeImportExtension. Use
importExtension ?? ''instead.Migration:
const config: CodegenConfig = { - emitLegacyCommonJSImports: false, + importExtension: '.js', }; -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Removed dependency
@graphql-tools/utils@^12.0.3↗︎
(fromdependencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Removed dependency
-
#11075
fa49a37
Thanks @eddeee888! - Remove unused@graphql-tools/utils
dependency -
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/typescript-operations@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the deprecated
emitLegacyCommonJSImportsconfig option and the--emit-legacy-common-js-importsCLI flagUse
importExtension(or--import-extension) to set the extension appended to relative imports.
WhenimportExtensionis not set, no extension is appended.@graphql-codegen/plugin-helpersno longer exportsnormalizeImportExtension. Use
importExtension ?? ''instead.Migration:
const config: CodegenConfig = { - emitLegacyCommonJSImports: false, + importExtension: '.js', };
Minor Changes
-
#11103
409ffbf
Thanks @jerelmiller! - Add support for graphql v17 fragment
arguments (experimentalFragmentArguments).To use fragment arguments, set the parser option in the root
config:const config: CodegenConfig = { config: { experimentalFragmentArguments: true } // ... }
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/schema-ast@7.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/typescript-resolvers@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Removed dependency
@graphql-tools/utils@^12.0.3↗︎
(fromdependencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Removed dependency
-
#11075
fa49a37
Thanks @eddeee888! - Remove unused@graphql-tools/utils
dependency -
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/typescript@7.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/typed-document-node@8.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: A plugin'svalidate
function now receives an info object as its fourth argument, matching thepluginfunction:
validate(schema, documents, config, { outputFile, allPlugins, pluginContext }). Custom plugins
that exportvalidateand readoutputFile,allPluginsorpluginContextas positional
arguments must destructure them from the fourth argument instead.Refs #11071
Minor Changes
-
#11103
409ffbf
Thanks @jerelmiller! - Add support for graphql v17 fragment
arguments (experimentalFragmentArguments).To use fragment arguments, set the parser option in the root
config:const config: CodegenConfig = { config: { experimentalFragmentArguments: true } // ... }
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11106
7366c63
Thanks @mohsinaliwork686-rgb! - Import
DocumentTypeDecorationwhendocumentModeisstringand there are no documents -
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/typescript@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0, inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0, inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/schema-ast@7.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/client-preset@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the deprecated
emitLegacyCommonJSImportsconfig option and the--emit-legacy-common-js-importsCLI flagUse
importExtension(or--import-extension) to set the extension appended to relative imports.
WhenimportExtensionis not set, no extension is appended.@graphql-codegen/plugin-helpersno longer exportsnormalizeImportExtension. Use
importExtension ?? ''instead.Migration:
const config: CodegenConfig = { - emitLegacyCommonJSImports: false, + importExtension: '.js', }; -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }.
Minor Changes
-
#11103
409ffbf
Thanks @jerelmiller! - Add support for graphql v17 fragment
arguments (experimentalFragmentArguments).To use fragment arguments, set the parser option in the root
config:const config: CodegenConfig = { config: { experimentalFragmentArguments: true } // ... }
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/documents@^2.0.0↗︎
(from^1.0.0, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/documents@^2.0.0↗︎
(from^1.0.0, independencies) - Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11106
7366c63
Thanks @mohsinaliwork686-rgb! - Import
DocumentTypeDecorationwhendocumentModeisstringand there are no documents -
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
7366c63,
fa49a37,
fa49a37]:- @graphql-codegen/add@8.0.0
- @graphql-codegen/gql-tag-operations@7.0.0
- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/typed-document-node@8.0.0
- @graphql-codegen/typescript@7.0.0
- @graphql-codegen/typescript-operations@7.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/graphql-modules-preset@7.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the deprecated
emitLegacyCommonJSImportsconfig option and the--emit-legacy-common-js-importsCLI flagUse
importExtension(or--import-extension) to set the extension appended to relative imports.
WhenimportExtensionis not set, no extension is appended.@graphql-codegen/plugin-helpersno longer exportsnormalizeImportExtension. Use
importExtension ?? ''instead.Migration:
const config: CodegenConfig = { - emitLegacyCommonJSImports: false, + importExtension: '.js', }; -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
409ffbf,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
- @graphql-codegen/visitor-plugin-common@8.0.0
@graphql-codegen/testing@6.0.0
Major Changes
- #11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version.
Patch Changes
- Updated dependencies
[fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37,
fa49a37]:- @graphql-codegen/plugin-helpers@8.0.0
@graphql-codegen/plugin-helpers@8.0.0
Major Changes
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: GraphQL 14 and 15 are no
longer supported. Thegraphqlpeer dependency is now^16.0.0 || ^17.0.0, so upgradegraphql
to version 16 or 17 before updating to this version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Node.js versions below
22.18.0 are no longer supported. Upgrade to Node.js 22.18.0 or later before updating to this
version. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: A plugin'svalidate
function now receives an info object as its fourth argument, matching thepluginfunction:
validate(schema, documents, config, { outputFile, allPlugins, pluginContext }). Custom plugins
that exportvalidateand readoutputFile,allPluginsorpluginContextas positional
arguments must destructure them from the fourth argument instead.Refs #11071
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE - Remove
isOutputConfigArrayandisConfiguredOutputThese functions were only used internally, and wrappers of simple functions.
-
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE: Remove the deprecated
emitLegacyCommonJSImportsconfig option and the--emit-legacy-common-js-importsCLI flagUse
importExtension(or--import-extension) to set the extension appended to relative imports.
WhenimportExtensionis not set, no extension is appended.@graphql-codegen/plugin-helpersno longer exportsnormalizeImportExtension. Use
importExtension ?? ''instead.Migration:
const config: CodegenConfig = { - emitLegacyCommonJSImports: false, + importExtension: '.js', }; -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE:@graphql-tools/*
dependencies are updated to their latest majors, which require Node.js 22.18.0 or later and
GraphQL 16 or 17. If you import@graphql-tools/*packages in your own code, update them to the
same majors to avoid duplicate installs.@graphql-tools/code-file-loader@9now extracts
#graphql-marked template literals by default, so code files that contain such templates can
produce newly found documents; check your generated output after upgrading. To keep the previous
behavior, setpluckConfig: { gqlHashComment: '' }. -
#11075
fa49a37
Thanks @eddeee888! - BREAKING CHANGE -config.generatesno
longer takesConfiguredPlugin[], takesConfiguredOutput[]insteadconfig.generates's previous typing allowed a value to be an array e.g.generates: { "src/gql/generated.ts": [{ typescript: {} }] }However, this never worked because this config is eventually passed into
normalizeOutputParam
which previously had this bug in the implementation:export function normalizeOutputParam(config) { // 0. When config is an array... if (isOutputConfigArray(config)) { // 1. `isOutputConfigArray(config)` was `Array.isArray(config)` -> returns true return { documents: [], schema: [], plugins: isConfiguredOutput(config) ? config.plugins : config // 2. ‼️ `isConfiguredOutput(config)` was `typeof config === 'object'` -> returns true. This is a bug because we are accessing `plugins` property of an array, which will ALWAYS be `undefined` -> the output is always rejected as "Invalid Codegen Configuration" } } if (isConfiguredOutput(config)) { return config } throw new Error(`Invalid "generates" config!`) }
Now, an array is still accepted, but as
ConfiguredOutput[]instead. For this major version
release, only the first array element is used, and@graphql-codegen/clilogs a warning when
there is more than one element.normalizeOutputParamnow returnsConfiguredOutput[]instead of a singleConfiguredOutput.@graphql-codegen/clialso throws its "Invalid Codegen Configuration" error when agenerates
array is empty or its first element is not a config object. This error is now a single generic
message, no longer naming the output file, and it shows a TypeScriptCodegenConfigexample with
theConfiguredOutputshape instead of the old YAML plugin-list example.
Patch Changes
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - dependencies updates:- Updated dependency
@graphql-tools/utils@^13.0.2↗︎
(from^12.0.3, independencies) - Added dependency
@graphql-tools/apollo-engine-loader@^9.0.2↗︎
(todependencies) - Updated dependency
graphql@^16.0.0 || ^17.0.0↗︎ (from
^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 || ^17.0.0,
inpeerDependencies)
- Updated dependency
-
#11075
fa49a37
Thanks @eddeee888! - Type theinfoargument ofPluginFunction
withPluginInfo, sopluginandvalidateshare one definition. -
#11075
fa49a37
Thanks @eddeee888! - Move@graphql-tools/apollo-engine-loader
from devDependencies to dependencies, since the published types import from it.