diff --git a/guides/plugins/apps/administration/adding-snippets.md b/guides/plugins/apps/administration/adding-snippets.md new file mode 100644 index 000000000..4a3fdaa7a --- /dev/null +++ b/guides/plugins/apps/administration/adding-snippets.md @@ -0,0 +1,12 @@ +--- +nav: + title: Add translations for apps + position: 30 +--- + +# Adding translations for apps + +Adding snippets to the administration works the same way for plugins and apps. The only difference is the file structure and that apps are not allowed to override existing snippet keys. The only thing to do, therefore, is to create new files in the following directory: `/Resources/app/administration/snippet` +On top of that, you need JSON file for each language you want to support, using its specific language locale, e.g. `de-DE.json`, `en-GB.json`. + +Since everything else works the same, please refer to our [Adding translations for plugins](../plugins/administration/adding-snippets) guide for more information. diff --git a/guides/plugins/plugins/storefront/add-translations.md b/guides/plugins/plugins/storefront/add-translations.md index d1b28605a..3aac61901 100644 --- a/guides/plugins/plugins/storefront/add-translations.md +++ b/guides/plugins/plugins/storefront/add-translations.md @@ -5,7 +5,7 @@ nav: --- -# Add Translations +# Add translations ## Overview @@ -41,7 +41,7 @@ Now that we know how the structure of snippets should be, we can create a new sn Here's an example of an English translation file: -```js +```json // /src/Resources/snippet/en\_GB/example.en-GB.json { "header": {