release-1766069402447
📦 graphql-yogaView on GitHub →
✨ 4 features🐛 2 fixes🔧 6 symbols
Summary
graphql-yoga 5.18.0 introduces the exported `GraphiQLRenderer` type and several enhancements to the Apollo Sandbox renderer, while plugin-persisted-operations now supports batching. Minor bug fixes and dependency updates accompany the release.
Migration Steps
- Import `GraphiQLRenderer` from `graphql-yoga` and update any custom `renderGraphiQL` implementations to match the new signature.
- If using Apollo Sandbox renderer, adjust code if you relied on the previous default element ID; you can now specify `target` or keep the default `#embedded-sandbox`.
- No other code changes required for the updated persisted operations handling.
✨ New Features
- Exported `GraphiQLRenderer` type from `graphql-yoga` to be used as the signature for the `renderGraphiQL` option.
- Added `target` option to Apollo Sandbox renderer allowing custom HTML element selection, defaulting to `#embedded-sandbox`.
- Updated Apollo Sandbox renderer to use `GraphiQLRenderer` type, set `initialEndpoint` from `graphiqlOpts.endpoint`, and set `includeCookies` from `graphiqlOpts.credentials`.
- Enhanced persisted operations handling in `@graphql-yoga/plugin-persisted-operations` to operate per parameters, enabling request batching.
🐛 Bug Fixes
- Fixed type definition for `renderGraphiQL` option in Apollo Sandbox renderer.
- Resolved margin and size layout issues in the rendered Apollo Sandbox HTML.
🔧 Affected Symbols
GraphiQLRendererrenderGraphiQLApolloSandboxRenderer.targetApolloSandboxRenderer.initialEndpointApolloSandboxRenderer.includeCookiespersistedOperationsHandler