/sanity-plugin-intl-input

Intl input for Sanity with a cleaner UI than a default solution

Primary LanguageTypeScriptMIT LicenseMIT

Intl plugin for Sanity

npm version

!! Breaking Change for V5

The ID structure for translated documents has changed. Your queries against Sanity will continue to work until you use the maintenance tab (new in V5) to update the ID structure. The change was made to improve the querying structure and to make better use of GROQ. The new structure looks as follows i18n.{baselanguage-document-id}.{language}. This means you could query all translations for a document as follows *[_id in path("i18n.{baselanguage-document-id}.*")]. This vastly improves the querying experience.

Default solution

When you want to create translations in Sanity they suggest following approach.
This definitely works, but makes the UI very clunky as you get more fields that require translations.

Default Solution

With intl-plugin

With the intl plugin you will get a cleaner UI for creating translatable documents as the translation is managed across multiple fields and it is even possible to manage document wide translations.

Simple translated object field Document wide translation
Intl Plugin Input Intl Plugin Document Translation

Documentation

  1. V4 to V5 migration guide
  2. Installation Instructions
  3. General Configuration
  4. How to use
  5. Datastructure
  6. Translation Maintenance
  7. GraphQL support
  8. Advanced languages