Releases: sanity-io/preview-kit
v2.1.0
v2.0.0
2.0.0 (2023-06-09)
⚠ BREAKING CHANGES
definePreview
and<PreviewSuspense>
are replaced by<GroqStoreProvider>
.usePreview
is replaced byuseListeningQuery
.@sanity/client
is now a peer dependency.
The migration guide outlines every breaking change and how to migrate your code
Features
- Live previews are now easier to build, have a much shorter bootup time and you no longer need separate preview versions of components as
useListeningQuery
can be disabled for production modes. token
are set in a single location,<GroqStoreProvider>
, instead of prop-drilled to every preview component.Suspense
boundaries now optional, you only need them if you're code-splittingGroqStoreProvider
withReact.lazy
Bug Fixes
- Preview hooks no longer perform queries while the initial dataset export is streaming, as this could lead to incomplete query results and unexpected cases of
null
.
This release is also available on:
v1.5.4
v1.5.3
v1.5.2
1.5.2 (2023-05-03)
Introducing Content Source Maps
Note
Content Source Maps are available for select Sanity enterprise customers. Contact our sales team for more information.
Content Source Maps are an optional layer of contextual metadata sent with queries to enable use cases such as Visual Editing, tracing content lineage, and more. Our implementation of Content Source Maps are based on an open standard posted on GitHub, and you can read the API documentation here.
Bug Fixes
- make
encodeSourceMap
optional (d03717b)
This release is also available on:
v1.5.1
v1.5.0
1.5.0 (2023-05-03)
Introducing Content Source Maps
Note
Content Source Maps are available for select Sanity enterprise customers. Contact our sales team for more information.
Content Source Maps are an optional layer of contextual metadata sent with queries to enable use cases such as Visual Editing, tracing content lineage, and more. Our implementation of Content Source Maps are based on an open standard posted on GitHub, and you can read the API documentation here.
This release is also available on: