graphql
17.1.0 · 4 Nov 2026MIT74.5M / weekRepositorynpmAtom feed
Upgrading graphql From 0.11.7 to 0.12.0
1 release in betweenevery note read
Reading releases, release notes and advisories…
- 3
- changes to make
- 0
- advisories fixed
- 4
- new
- 9
- fixes
Before you upgrade
Tick each one off as you go- Breaking0.12.0
- Breaking0.12.0
- Deprecated0.12.0
Release by release
- Breaking
As a result, there are a number of breaking changes to be aware of, especially for those building tools with GraphQL.js.
- Breaking
Detect breaking changes within directives
- Deprecated
A new function
getIntrospectionQuery()is exported, and the existingintrospectionQueryconstant is deprecated. This helps improve the flow types and allows for some flexibility and options. - New
Allow serializing scalars as null.
- Breaking
19 other lines we could not sort, mostly version bumps
- 0.12.0
Schema is now validated as part of a new exported function
validateSchema()instead of during construction. - 0.12.0
Validation errors for value literals (and variable values) are greatly improved, doing so results in a change to the standard set of validation rules. (#1126, #1133, #1144, #1153)
- 0.12.0
GraphQL can now execute synchronously if all resolvers are synchronous functions. This means
execute()may no longer return a Promise if execution completed synchronously. Thegraphql()function will still always return a Promise, but a newgraphqlSync()function guarantees synchronous completion (or throws if any resolver does not complete). This unlocks exciting new use cases for querying over static data-sets and caches. (#1115, #1120) - 0.12.0
Update to match Schema definition language latest specification. (#1102, #1117, #1139)
- 0.12.0
Descriptions in the schema definition language are now represented as preceding strings rather than comments.
- 0.12.0
Flow types for the parsed GraphQL AST and GraphQL Errors are now read only. This may result in new flow errors being detected in your codebase if you manipulate ASTs and Errors. (#1116, #1121, #1122)
- 0.12.0
Flow types have been added to
visit(). As with any flow type improvement, this could expose real issues with your existing codebase. - 0.12.0
The Wrapping Types
GraphQLNonNullandGraphQLListare now flow typed as covariant and operate like a function instead of a class. This means that you should no longer typenew GraphQLList(someType)and instead favorGraphQLList(someType). - 0.12.0
A new function
printError()is exported which highlights any blame lines from the original sources. Useful for printing errors to consoles. (#1129, #1131) - 0.12.0
Improved aggregate NullableType and InputType flow types. As with any flow type improvement, this could expose real issues with your existing codebase.
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.