Skip to main content
Version: v10.x - Umbraco 10

Custom JSON Properties

If your property editor stores its values within a JSON object, you can use the config file to tell Translation Manager how to interpret your properties data. For example, if you have a property that stores its data in the following format:

{
"Key", "some-key-value",
"Title", "my property title",
"Content", "<p>some rich text content</p>"
}
note

In Umbraco 9/10 the mappings are stored in a config/translation_mapping.config file. This file does not exist by default and you will need to create it if you want to define custom mappings.

If your property editor used the JSON above then you can map this with the following configuration in the config/translation_mapping.config. You will need to define the config using the <custom> or <grid> config nodes (see below for details of how the grid naming works).

<mappers>
<custom>
<config alias="My.Custom.Property">
<properties>
<property name="Title" alias="Umbraco.Textbox" />
<property name="Content" alias="Umbraco.TinyMCEv3" />
</properties>
</config>
</custom>
</mappers>

This config tells Translation Manager to treat all My.Custom.Property values as JSON and to extract the title and content values when creating and importing translations.