Technical doc & features
Configuring Files to Sync with Prismy
Prismy allows you to configure which localization files to sync by simply
adding a prismy.json
file at the root of your repository. This configuration
file lets you define the main branch, primary language, and the specific files
you want to synchronize.
Example Configurations
Nested JSON Format with Alphabetical Sorting
Flat JSON Format Without Sorting
Configuration Options
mainBranch
: The default branch for Prismy - can be your staging or preprod branch.mainLanguage
: The default source language for translations.filesToSync
: An array defining which files to sync, with options for sorting and format.sort
: Defines how keys within the files are organized (alphabetical-order
ornot-sorted
).format
: Specifies whether the JSON files areflat-json
(single-level key-value pairs) ornested-json
(hierarchical structure).i18nLib
Defines the lib you are using, useful for Prismy to handle the pluralisation properly for instance. Should be “i18next”, “polyglotjs”, “react-intl” or any other lib you are usingfiles
: A mapping of language codes to file paths that should be included in synchronization.