PageSourceSearch

https://www.graphql-js.org/_next/static/chunks/pages/docs/experime…-specification-features-456d6ce6dd4edbf7.js

js graphql-js.org collected 2026-10-04 01:46:31 UTC 5,471 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4637],{1332:function(e,n,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs/experimental-specification-features",function(){return r(4294)}])},4294:function(e,n,r){"use strict";r.r(n),r.d(n,{useTOC:function(){return l}});var i=r(5893),a=r(7812),s=r(3412),t=r(8925);function l(e){return[{value:"Incremental delivery",id:"incremental-delivery",depth:2},{value:"Disabling error propagation",id:"disabling-error-propagation",depth:2},{value:"Fragment arguments",id:"fragment-arguments",depth:2}]}n.default=(0,a.c)(function(e){let{toc:n=l(e)}=e,r={a:"a",code:"code",h1:"h1",h2:"h2",li:"li",p:"p",ul:"ul",...(0,t.a)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(r.h1,{children:"Experimental Specification Features"}),"\n",(0,i.jsx)(r.p,{children:"GraphQL.js v17 adds several experimental GraphQL specification proposals.\nThese features are intentionally explicit: syntax usually requires a parser\noption or schema directive, and execution behavior usually requires a\nspecific executor."}),"\n",(0,i.jsx)(r.p,{children:"GraphQL.js-specific runtime APIs, such as abort signals, execution hooks, and\nthe harness API, are documented separately because they are not GraphQL language\nfeatures."}),"\n",(0,i.jsx)(r.h2,{id:n[0].id,children:n[0].value}),"\n",(0,i.jsxs)(r.p,{children:["Incremental delivery adds ",(0,i.jsx)(r.code,{children:"@defer"}),", ",(0,i.jsx)(r.code,{children:"@stream"}),", and execution results with\ninitial and subsequent payloads."]}),"\n",(0,i.jsxs)(r.p,{children:["The relevant GraphQL.js APIs are ",(0,i.jsx)(r.code,{children:"GraphQLDeferDirective"}),",\n",(0,i.jsx)(r.code,{children:"GraphQLStreamDirective"}),", and ",(0,i.jsx)(r.code,{children:"experimentalExecuteIncrementally()"}),".\nGraphQL.js does not include the directives in ",(0,i.jsx)(r.code,{children:"specifiedDirectives"}),"; a schema\nthat uses them should add them explicitly and execute matching operations with\n",(0,i.jsx)(r.code,{children:"experimentalExecuteIncrementally()"}),". If you add them programmatically with the\n",(0,i.jsx)(r.code,{children:"GraphQLSchema"})," ",(0,i.jsx)(r.code,{children:"directives"})," config property, include ",(0,i.jsx)(r.code,{children:"specifiedDirectives"})," as\nwell. Providing ",(0,i.jsx)(r.code,{children:"directives"})," replaces the default directive list, whose default\nvalue is ",(0,i.jsx)(r.code,{children:"specifiedDirectives"}),"."]}),"\n",(0,i.jsxs)(r.p,{children:["See ",(0,i.jsx)(r.a,{href:"/docs/defer-stream",children:"Defer and Stream"}),"."]}),"\n",(0,i.jsx)(r.h2,{id:n[1].id,children:n[1].value}),"\n",(0,i.jsxs)(r.p,{children:["Disabling error propagation lets an execution error resolve the errored response\nposition to ",(0,i.jsx)(r.code,{children:"null"})," without nulling out non-null parent fields. GraphQL.js exposes\nthis through the experimental operation directive\n",(0,i.jsx)(r.code,{children:"@experimental_disableErrorPropagation"}),"."]}),"\n",(0,i.jsx)(r.p,{children:"The motivations are:"}),"\n",(0,i.jsxs)(r.ul,{children:["\n",(0,i.jsx)(r.li,{children:"Preserve useful partial data. A failed field should not necessarily remove\nsibling response data that resolved successfully."}),"\n",(0,i.jsxs)(r.li,{children:["Keep normalized caches safe. A bubbled ancestor ",(0,i.jsx)(r.code,{children:"null"})," can look like a real\nobject update when only one descendant field failed."]}),"\n",(0,i.jsxs)(r.li,{children:["Separate execution errors from true semantic nullability. Schema nullability\nshould be able to express whether ",(0,i.jsx)(r.code,{children:"null"})," is a normal domain value, not whether\na resolver might fail."]}),"\n"]}),"\n",(0,i.jsxs)(r.p,{children:["This feature is part of a longer nullability and error-handling proposal thread.\nThe latest proposals to follow are\n",(0,i.jsx)(r.a,{href:"https://github.com/graphql/graphql-spec/pull/1163",children:"Error Behavior"}),", which\ndefines client-selected ",(0,i.jsx)(r.code,{children:"onError"})," modes, and\n",(0,i.jsx)(r.a,{href:"https://github.com/graphql/graphql-spec/pull/1208",children:"Service Capabilities"}),", which\npulls the capabilities work out into the introspection mechanism clients use to\ndiscover support, accepted modes, and default behavior."]}),"\n",(0,i.jsxs)(r.p,{children:["See ",(0,i.jsx)(r.a,{href:"/docs/disabling-error-propagation",children:"Disabling Error Propagation"}),"."]}),"\n",(0,i.jsx)(r.h2,{id:n[2].id,children:n[2].value}),"\n",(0,i.jsxs)(r.p,{children:["Fragment arguments let named fragments declare local variables and let named\nfragment spreads pass values for them. GraphQL.js exposes the syntax through the\n",(0,i.jsx)(r.code,{children:"experimentalFragmentArguments"})," parser option. The AST surface includes\n",(0,i.jsx)(r.code,{children:"FragmentArgumentNode"}),", and execution supports the resulting values."]}),"\n",(0,i.jsxs)(r.p,{children:["See ",(0,i.jsx)(r.a,{href:"/docs/fragment-arguments",children:"Fragment Arguments"}),"."]})]})},"/docs/experimental-specification-features",{filePath:"pages/docs/experimental-specification-features.mdx",timestamp:1781535013e3,pageMap:s.v,frontMatter:{title:"Experimental Specification Features",sidebarTitle:"Experimental Specification Features"},title:"Experimental Specification Features"},"undefined"==typeof RemoteContent?l:RemoteContent.useTOC)}},function(e){e.O(0,[7812,3412,2888,9774,179],function(){return e(e.s=1332)}),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.