Skip to content
This repository has been archived by the owner on May 3, 2022. It is now read-only.

Commit

Permalink
PlatformUI translation doc
Browse files Browse the repository at this point in the history
  • Loading branch information
stephaneDiot committed Mar 6, 2017
1 parent 55e53ba commit 7cf8855
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,3 +157,22 @@ Then, you can run the unit tests with:
```
$ php vendor/bin/phpunit
```
* Translation
To use translations in PlatformUI you have to use :
In the javascript files:
```javascript
Y.eZ.trans('the.string.identifier', {}, 'domainname')
```

In templates :

```template
{{ translate 'the.string.identifier' 'domainname' }}
```

To generate the .xlf translation file (in PlatformUIBundle/Ressources/translations)
you need to use the script defined in PlatformUIBundle/bin/extract-translations.sh
(https://github.com/ezsystems/PlatformUIBundle/blob/master/bin/extract-translations.sh)

0 comments on commit 7cf8855

Please sign in to comment.