Manual localization is important here.
- create language files in json format
- create a locale list file in json format.
- download add-on package (xpi file) from Add-on Builder
- rename the .xpi file extension to .zip
- deploy zip file
- create locale folder in addon root directory
- copy locale files to locale folder
- copy the locale list file to the root folder
- zip all files and folders in the root folder.
- rename the .zip file extension to .xpi
file tree:
my-addon | locales.json | +---data +---lib +---locale en-US.json fr-FR.json ja-JP.json
samples:
locales.json {"locales":[ "en-US", "fr-FR", "ja-JP" ]} en-US.json { "test": "test en-US", "test2": "test2 en-US" } fr-FR.json { "test": "test fr-FR", "test2": "test2 fr-FR" } ja-JP.json { "test": "test ja-JP", "test2": "test2 ja-JP" }
source share