Closed adjagu closed 2 years ago
Looks good indeed.
Using the standard implementation is great. I just don't like the format they use (__MSG_ + messageName + __
) but we can't do anything about it.
I just would want to discuss about the way you name the messages. Wouldn't something like <scope>.<message>
be better?
Example:
"manifest.name": {
"description": "Web-extension name in the manifest file.",
"message": "MWMBL Web Crawler"
},
"popup.logs.successMessage": {
"description": "Success message shown in the log page.",
"message": "$URL$ as been successfully crawled"
"placeholders": {
"url" : {
"content" : "$1",
"example" : "https://mwmbl.org"
}
}
},
This can be used to add context to translated keys.
Thanks for the contribution, great work!
Added internationalization.
With this others will be able to translate the extension into languages other than English.
To add a new translation a person would do the following:
_locales
directoryde
for German,fr_FR
for French_locales/en/messages.json
to the directory created in step 1