đź‘‹ Next.js Conf 2024: Come build, party, run, and connect with us! See all events

Publishing schemas and snippets

Select draft OR published document

Setting up a live preview and want to fetch a document's draft, with a fallback for the published document when there are no drafts? Check this out.

Formidable
Go to Select draft OR published document

One or the other validation

This validation can be used if you have two fields and you require one or the other to be filled

Roboto Studio
Go to One or the other validation

List Referring Documents (Backlinks) in Sanity

Studio v2

This recipe is a UX affordance for Sanity Studio, which makes it easier for editors to manage heavily cross-referenced documents. It provides a list of backlinks to referring documents.

Go to List Referring Documents (Backlinks) in Sanity

Easy peasy URL Slug

Studio v2

Quickly and easily validate your slug without having to work out the regex syntax

Roboto Studio
Go to Easy peasy URL Slug

Breaks for Portable Text

How to add different types of “breaks” for Portable Text that can be translated to horizontal rules, “read more”, sections, chapters, and so on.

Knut Melvær
Go to Breaks for Portable Text

Other contribution categories