Index
Edit

Structure builder

Introduction

The heart of Sanity is letting developers and editors tailor the best possible content management experience. This includes being able to configure how your editor works, by defining document types and fields in the schemas for Sanity Studio. Documents are listed in the desk tool part of the Studio. By default, document types are listed in the first, leftmost pane, with their respective documents shown in the second pane, and editing of the selected document in the third. With structure builder, it’s up to you how shallow or deep this hierarchy should be.

That's why Sanity Studio comes with the structure builder, that gives you full flexibility in how your content should be organized in the studio, without forcing you to change the underlying content model. For instance, you might want to:

  • Restrict a type to one single document with a given id (typically some global configuration)
  • Easily navigate to a specific document in the root of the navigation structure (think “featured items” in an app or on a website, for instance)
  • Create a more workflow-focused navigation structure (think “needs review”, “awaiting publication” and similar)
  • Display a certain document type in a custom way instead of in the default editor
  • Use an external API to control how documents are structured in the studio (for example setting up a newsroom where different “modes” of the studios can be pushed remotely and in real time)

To achieve this, you can define what we call a “structure” for the desk tool. A structure configuration may seem a bit daunting the first time, but we promise that it’s pretty easy to use once we have broken down the central concepts. And it will give you a lot of flexibility with relatively few building blocks.

Previous: LocalizationNext: How it works