@tinloof/sanity-toolkit
Utilities, schemas and components for Sanity.io studios.
The most important bits of this package are:
schema/reusedFields
and schema/objects
- commonly-used, fundamental schemas shared across all sites.schemas/documentSchema.ts
- builds a localizable & ordered document schema based on configuration nested in its custom
object. Also enhances the provided fields
with common fields such as slug
, seo
and publishStatus
, if applicable.schemas/blockSchema.ts
and schemas/settingsSchema
- similar to documentSchema
, but applicable to blocks and the settings document, respectively.parts/buildStructure.ts
- takes in a configuration for the shape of the studio's Desk and outputs a Structure Builder to render localized, ordered and neatly organized menus of documents.components/StudioDocs.tsx
- minimal component that renders a Docsify instance to document the studio from inside of it. The actual documentation lives in the front-end's public folder - @tinloof/remix-cli/template/public/studio-docs
for the template.