-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
A suggestion for simple, yet efficient variable interpolation in js translations #24
Conversation
I like this approach as translators get a better impression what the variables stand for. This is much easier to translate than |
Comparing this approach with #16: |
From my POV we have the exact same functionality without adding extra libraries and with the added benefit that it easier for translators as you also stated earlier. |
A suggestion for simple, yet efficient variable interpolation in js translations
Which requires no extra libraries. This is of course for post-4.5, just wanted to get it out of the door while I remembered.
Usage is imo very intuitive:
Not that I want to stir up a discussion of whether macaroni is pasta or not, but my mind was totally blank when I should find an example :-P
btw, I can't take credit for it http://stackoverflow.com/questions/1408289/best-way-to-do-variable-interpolation-in-javascript#answer-1408373