Releases: graphql-nexus/nexus
next
Features
- 4d8e371 better esm support, remove top-level node imports (#1112)
- eec4b91 add sourceType option to fieldDefinition (#1106)
- 9875e90 Add Schema Directives to SDL (#952)
- 11d0282 allow specifying custom directives in makeSchema (#1065)
- aaa4520 Run both formatTypegen and prettier formatter if given (#1042)
- 7349e36 allow specifying custom directives in makeSchema (#1064)
- 892af67 Use ReadonlyArray in typings (#1041)
Fixes
- 601c2f0 Replace outdated note (#1153)Co-authored-by: Andrew Carlson [email protected]
- 8e65081 remove hasSDLDirectives internal state (#1091)
- 7ee48c4 add missing as const on the RequestDirectiveLocation (#1090)
- 123dc61 incorrect logic in backward pagination (#1084)
- 251af94 update snapshots for change in #1083
Improvements
Chores
- 1e6b921 remove irrelevant paragraph in docs (#1128)
- e9dc7e0 Fix codecov
- 9a10507 attempt to fix the dripip workflow, again
- df9cb70 update the dripip workflow, bump lint-staged
- b906288 change facebook.github.io to relay.dev links (#1083)
- bc12ca0 use dripip reusable workflow
Unspecified Changes
-
Replaced Prisma reference
-
Updated copyright info
Update comment to reflect the current behavior as per src/typegenUtils.ts
v1.3.0
1.1.0
Features
- df7d137 field config with name (#938)
- 2759c55 TO_NEXUS symbol for adding types via metaprogramming (#932)
- 3a92760 Accept
ReadonlyArray<T>
for enum members (#916) - fbcfba3 connectionPlugin internal modifications (#811)
- bb936cb add plugin support for inputObjectType (#799)
- 666746c allow implementing interfaces in extendType (#774)
- 4f3cef9 Add custom name options to Relay Connection plugin (#744)
Fixes
- 81ec5c0 Allow meta types to be wrapped with null/list (#935)
- 690abb7 correct edge node typing (#876)
- 7ff557b sync should gen artifact logic with what docs say(#884)
- 7f16b8b cast NexusNonNullDef to prevent union type complexity error (#846)
- 27e35e5 reduce iteration in connections (#843)
- aa283ad invoke correct fn on global extended connection/edge (#814)
- 1f5b025 pass down source into extended connection fields (#812)
- af73f66 Allow specifying overrides for builtin scalars (#795)
Improvements
- 2b0708d refactor: TO_NEXUS -> NEXUS_TYPE / NEXUS_BUILD (#934)
- 2e1c32b refactor: move makeSchema into separate file from builder (#927)
- d2e586b refactor: make errors more readable (#887)
- 74c93e2 refactor: add importsNotUsedAsValues: error to force import type (#872)
Docs
- 571fa4d docs: Add link to GH Actions
- a59273d docs: update the example of using a custom typing to GraphQL context value (#871)
- 3f78131 docs: vanilla nexus migration from nexus-plugin-prisma (#838)
- 46ad529 docs: add more information to field authorize plugin (#821)
- 0b28c77 Docs: Correct an object's value in the tutorial (#808)
- 0ce49b9 docs: adjust migration guide from nexus-plugin-prisma (#818)
- 7f0dd11 docs: add migration guide for nexus-plugin-prisma (#817)
- cb1e17e docs: Fix variable naming for express import (#802)
- ebcdb29 Fix a typo in JSDoc example (#937)
- 10ea65f add formatTypegen example (#930)
- 031c772 Fix prisma link in examples README (#912)
- 189a5be fix proper variable name (#904)
- 70eda57 nexus nullability defaults (#900)
- 5844b7f update API link to Prisma object modeling (#890)
- 7b84cd6 broken link (#881)
- 3c18d6c Nexus nullability defaults to that everything is null by default
- 9a3915e updated prisma references (#874)
- ce1bd8c fix typo in abstract types documentation (#873)
- 5056129 removed databaseUrl in final code sample testing (#863)
- c89c72b Change --transpileOnly to --transpile-only from star-wars example (#859)
- 3050c3b Updated getting started tutorial (#852)
- 291e86a fix broken link in 070-make-schema.mdx (#851)
- 4625a13 update 010-object-type.mdx (#847)
- 8827f28 Update 06-chapter-5-persisting-data-via-prisma.mdx (#848)
- d220d31 deprecated nexus/testing module #833 (#840)
- e3b414d Fix Docs 061-list-nonNull.mdx (#837)
- 43f1da2 Updated tutorial docs (chapter 5 persisting-data-via-prisma) to fix cli install instructions (#834)
- bfdd420 adoption guide link to with-prisma example fix (#794)
- de04999 use db push (#793)
- 025d82e Update 010-object-type.mdx (#791)
- b327841 update migrate commands (#792)
- 0788e86 update context type config to new api
- 1c7b9b1 Change backingTypesMap to mapping (#782)
- 55bca2d fix code example (#781)
- cb22957 remove tutorial intro wip warning
- 217779b remove outdated prisma plugin config docs (#777)
- fe1dd14 Small changes to docs (#776)
- 3f27f9e example MIT license
- 91c775e update example deps
- d996212 remove obsolete prisma plugin settings type
- a782944 remove obsolete prisma plugin example
- b69b30f remove todo auth chapter
- ea3f994 fix framework migration package ambiguity
- 9afc643 add docs for common field config of prisma plugin (#735)
- 5116a18 use sourceType in locally configure Source Types (#769)
- 2141a77 Update 04-chapter-3-adding-mutations-to-your-api.mdx (#751)
- 8c324a6 Add import db in diff to match code (#755)
- bcc0cee update tutorial to use new prisma migrate preview (#752)
- 1a3c3c5 fix examples for abstract types to work with Typescript (#743)
- c4b35b3 fix api usage (#765)
- fcc66eb fix bad context import documention (#756)
- 2e76a4f fix docs overview link to repo examples (#763)
- c1aa267 Update 07-chapter-6-testing-with-prisma.mdx (#766)
- bef7786 use new prisma migrate command (#732)
- c2acf9b fix links in prisma plugin index page
- 2b44900 better prisma plugin index page
- 0ed742a fix URLs point to git repo trunk
- 5c4d6de update git repo URLs
- 4c52f59 update package git repo url
- bd9ea3f try fixing image URLs
- 1ebae9f update nexus ver in examples
- 6b5fcce rename Nexus Schema to Nexus (#700)
- 16ac615 chore(docs) Fix Broken Link in Tutorial Chapter 2 (#877)
- 31a6137 Fix graphql docs link for interfaces (#913)
- cfff794 updated test script and server start (#882)
- 3f05c1d Resolve bullet indentation issue (#879)
Chores
1.0.0
BREAKING CHANGES
rename package to nexus
You will now need to install Nexus Schema from the npm package nexus instead of @nexus/schema.
forbid null for descriptions
It is no longer permitted to pass null to description of enum, objects, args, input objects, interfaces, unions. Now you must pass either a string or nothing.
remove backward compatible code and warnings
- Legacy
resolveType
is no longer part of the API - Legacy scalar shorthands are no longer supported
declarativeWrappingPlugin
is no longer enabled by defaultScalarInputFieldConfig
type is removed
Rename typegenAutoConfig and rootTyping
Make contextType
independent of source types
Features
- 78b8b08 (breaking) remove backward compatible code and warnings (#730)
- d66e8f1 (breaking) rename typegenAutoConfig and rootTyping (#723)
- 642be8b (breaking) make contextType independent of source types
- dc1e21b pass connection args to field extensions (#710)
- 96368ab allow arbitrary extensions on nexus types (#684)
- 0cff220 Don't force async if connection resolvers are sync (#707)
- 9d0f4f4 add
.asArg
for enum, fix default typings (#708) - cf5b269 support
graphql@^14.5
(#677) - 71ea266 allow promise to be returned from
pageInfoFromNodes
- bb13600 add
requireResolver: false
- af7c06c connection can accept non-String cursor
Fixes
- 242046c subscriptionField overload for builder api access (#694)
- 6220d85 proper typings for edge extension
- 927d4b8 export connection plugin args
- 8d14709 custom edge fields not resolved
Improvements
- 80ad531 (breaking) improve: rename package to nexus (#699)
- 5377df5 docs: cover abstract type funcs with jsdoc
- 3531a31 docs: cover root types with jsdoc
- 57ca56f docs: cover arguments related things with jsdoc (#726)
- 0a43cbc (breaking) improve: forbid null for descriptions
- 7dbb4ac docs: cover isTypeOf and extension with jsdoc (#720)
- 405ee53 docs: cover resolve method with jsdoc
- 08ce751 docs: add jsdoc for type prop on field config
- 6f51434 docs: cover the output type builder api with jsdoc (#715)
- e05a50e docs: cover extendType with jsdocs
- 2c8102b docs: cover objectType with jsdocs (#703)
Docs
- 81f2e37 docs: move source type section into its own guide (#711)
- 0191f69 docs: add sticky table of content
- 1da85cf marker outside of li, fix positioning (#719)
- c6a8399 add feedback loop and code re-use to Why Nexus (#725)
- fa3fd96 update "Why Nexus" (#712)
- 02bff7d use plain JS objects for storing the context (#718)
- c2a3ef9 update tutorial testing chapter (#709)
- b5e3335 own guide for nullability
- c16f6c6 fix typo
- 96b31d3 fix typo
- a9ca189 fix many things in the tutorial
- 947b04a fix common to install test deps in tutorial
- df3819e fix errors in next.js guide
- e3253ab add nexus next.js adoption guide (#691)
- 27d95d8 code sandbox for subscriptions
- abed6e0 update playground link to codesandbox
- 1e4fd3c fix nullability yaml frontmatter
Chores
v0.19.2
Fixes
Improvements
Chores
v0.19.1
v0.19.0
Breaking Changes
SDL file generation by default in development
SDL file generation will be enabled by default in development now.
If you were enabling it manually before and outputting to project root at schema.graphql
You can probably now just rely on the default.
If you were relying on the default to disable SDL file generation before then now you need to pass an explicit false:
makeSchema({
outputs: {
schema: false
}
})
Highlights
Abstract types system
New Abstract types system. Learn more at https://nxs.li/guides/abstract-types.
Type functions for list & nullability & .nonNull / .nullable chaining
New API for specifying list and nullability types. Learn more at https://nexusjs.org/docs/api/list-nonNull.
All Changes
Features
- 1551506 Improved description for types on output method / output field (#666)
- 5ab7dd3 Simplified upgrade path w/ better warning messages (#663)
- 306dbaa .nonNull / .nullable chaining, additional cleanup (#655)
- 618521d (breaking) SDL file generation by default in development (#652)
- 481e2c7 Allow contextType to specify an TypingImport config (#606)
- 4f4f9f4 add onFieldDefinition / onArgDefinition / onInputFieldDefinition (#640)
- bfcc959 add
t.modify
API for modifying inherited fields (#634) - 94ba687 deprecate plugin onInstall return for consistent API (#637)
- de832e7 type functions for list & nullability (#538)
- 967d2df abstract types system (#602)
Fixes
- 57bb5b0 Ensure we can modify nullability of an interface field (#662)
- 5c73102 Make custom scalars work with interfaceType (#661)
Improvements
- eb04d8f SDL converter list/nonNull chaining (#660)
- 506b61b deps: update all to latest (#649)
- 3a3d03b refactor: move wrapping helper fns to definitions/wrapping.ts (#643)
- 9ba7d9b refactor: Simplify typegen with keyof and intersection types (#628)
- e33906c refactor: remove namespace, separate internal types (#627)
- bff7008 resolveType warning, restore declarativeWrapping list behavior (#658)
- 1e11720 Refine exports for plugins (#639)
Docs
- f7b9cf8 docs: fix typo
- f49d0b0 update to use new 0.19 api (#667)
- 3e8843f add atomicOperations setting for prisma plugin (#587)
- 75c4c09 Add release changelog entries to CHANGELOG.md (#656)
- 36503f7 @tgriesser/schemats for simpler DB output in ghost example (#633)
- 45938cf fix little typo in 021-abstract-types.mdx (#624)
- 5870d5e fix installation note (#609)
Tests
v0.18.0
Breaking Changes
Remove resolver shorthands
Resolver shorthand API is now removed. The following will now not typecheck:
t.string('foo', () => ... )
Instead use:
t.string('foo', { resolve: () => ... })
Runtime support is still intact but will result in a logged warning. Runtime support will be removed in the next Nexus release.
Remove dynamic output builtins
ext
is no longer exported. The relayConnectionField
and collectionField
dynamic output methods have been removed. In their place try the connection
plugin.
All Changes
Features
Fixes
- 2e93338 deduplicate interfaces implementing interfaces (#608)
- 0064dc9 #588, #384 non-null list items & connection nullability (#598)
Improvements
- f609380 (breaking) remove resolver shorthands (#592)
- 9f01342 (breaking) remove dynamic output builtins (#590)
Docs
Chores
v0.17.0
Features
-
9bfdf2c allow interfaces to implement other interfaces (#496)
-
b4e0deb add onObjectDefinition / onInputObjectDefinition (#533)
-
f8d164a error feedback if root typing path is invalid (#557)
This may be a breaking change if you were relying on pointing root typing path to a non-file for some reason in the past. We think for almost all users this will not be a breaking change however.
Fixes
- 10c5f8b "union too complex to represent" for large union types (#571)
- cc12ec1 (connection plugin) add deprecated, description, nullable to connectionField (#578)
- de7cdfd (connection plugin) various fixes (#569)
- Global connection field extensions were never executed
- Typings of global connection field extension (root, args and the resolver return type was wrong)
- Typings of local connection field extension (everything was any)
- 2edfcfa subscription type static typings (#564)
- 10208e3 input fields with default should not be typed as optional (#563)
Improvements
Docs
- 489b5ab docs: Fix ts-node-dev flag in the docs (#529)
- fb1216e header media query (#554)
- 2aaaf5c fix nullabillity guard docs (#575)
- 980920a fix for outdated prisma-labs link in the documentation #518 (#572)
- 9960015 Update 06-chapter-5-persisting-data-via-prisma.mdx (#574)
- e65f6ef Remove references to nexus framework (#528)
- c68a94c fix typo in migration guide (#527)
- 69af932 fix typo in nexus framework migration guide (#526)
- 8cea40a Fix a prisma client call b/c latest Prisma Client (#535)
- 0a6db6a fix link to announcement (#544)
- e2cfcb0 fix typo in 02-chapter-1-setup-and-first-query docs (#547)
- ebdb55a Update docs content (#553)
- 00fb8a6 fix duplicate in 020-nexus-framework-users.mdx (#561)
- 04fe2f5 touch api/schema.ts (#562)
- ceeea8c fix typos
- d4d32f7 fix migration guide ts-node command
- 0dd8ea3 Fix a typo in 030-neuxs-framework-prisma-users.mdx (#537)
- d1bb819 Remove framework mention, update link (#525)
Chores
v0.16.0
BREAKING CHANGES
- c7eff85 output types & list items are now nullable by default (#508)
- 0ee644b upgrade to graphql v15 (#486)
MIGRATION GUIDE
As Nexus Schema just made output types and list items nullable by default, there's a couple of changes you need to do to produce the same schema as before the update.
Changing global defaults to revert to non-nullable output types
import { makeSchema } from '@nexus/schema'
makeSchema({
+ nonNullDefaults: {
+ output: true
+ }
})
Changing type-level configuration to revert to non-nullable output types
import { objectType } from '@nexus/schema'
objectType({
name: 'User',
nonNullDefaults: {
+ output: true
}
definition(t) {
/* ... */
}
})
Updating lists output types to be non-nullable
import { objectType } from '@nexus/schema'
objectType({
name: 'User',
definition(t) {
t.field('posts', {
- list: true
+ list: [true]
})
}
})
Features
- c7eff85 (breaking) output types & list items are now nullable by default (#508)
- efa96cb new docs site (#500)
- 0ee644b (breaking) upgrade to graphql v15 (#486)
Fixes
- e4a68e5 config file fixed (#522)
- 646879d change netlify config (#519)
- 796add7 Github link
- b7ecbb0 Logo URL and Github link
- 2327a94 force release
- 3c38a65 message for missing resolveType in interfaces (#495)
Improvements
- 2fef488 tmp: tmp/index.html
- 99b34f6 temp: Temporary redirects for old nexus.js.org (#514)
- 5e156ac docs: update asNexusMethod example with the changes from #473 (#476)