question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support for translations in resource bundle files (.properties)

See original GitHub issue

Hi, would you be open to add support for providing ember-intl translations via a resource bundle files?

If ember-intl does this, editors like intellij provide an improved editor for translating keys:

https://www.jetbrains.com/help/img/idea/2018.2/bundleEditor.png

It works if the editor finds suffixed .properties files in a directory. It’ll merge them into a resource bundle and use a special editor for editing.

From what i can tell it should be possible to support these as the format is very similar to the yaml/json that ember-intl already supports.

The only open question would be how ember-intl detects the locale properties file. As far as I can tell, intellij requires the format .*_[a-z].properties.

One could solve this by transforming any properties file, using a locale suffix, into a JSON translation:

- i18n_de.properties
- i18n_en.properties

This could cause issues if a user creates multiple files with the same suffix, e.g.

- app_de.properties
- shop_engine_de.properties

One could solve this by requiring a specific prefix for each properties file or maybe add a feature to merge multiple translations in the same language.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:12 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
Turbo87commented, Aug 3, 2018

I’ll look into it when I’m back from vacation 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Resource Bundle Translator - IntelliJ IDEs Plugin | Marketplace
Mass translate your resource bundle files with ease by using the free Google ... Quick Help. ... Select in the project explorer one...
Read more >
ResourceBundle Translation Instructions - Oracle Help Center
Each property in a ResourceBundle.properties file is a key-value pair, in the format key=value . Make sure that only the values are translated....
Read more >
Creating localization resources - IBM
For each supported language, a file contains translated values for all of the keys. About this task. Tip: A localization resource bundle that...
Read more >
Java Localization using Resource Bundle .properties files
After you extracted all strings to resource bundles, you can easily check your application using Pseudo-translate and view which strings are altered and...
Read more >
Java ResourceBundle - internationalization and localization in ...
A resource bundle is a Java properties file that contains locale-specific data. It is a way of internationalizing Java applications by making ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found