Skip to content
This repository has been archived by the owner on Aug 17, 2023. It is now read-only.

Provide simpler syntax for translated text #58

Open
rowanseymour opened this issue Feb 7, 2017 · 2 comments
Open

Provide simpler syntax for translated text #58

rowanseymour opened this issue Feb 7, 2017 · 2 comments

Comments

@rowanseymour
Copy link
Member

Or make all plain text optionally translatable?

Putting some translatable text inside a tag (e.g. <b>{% trans "Hello" %}</b>) is a very common pattern but currently requires 2 lines, e.g.

%b
  - trans "Hello"

Would be nice to make this pattern more succinct, or possibly make all plain text optionally translatable? That is...

%b Hello

Would become <b>{% trans "Hello" %}</b> if "auto-i18n" is enabled.

@nicpottier
Copy link

Was thinking another option that might have a nice parallel would be using _

Maybe?

%b_ Hello

@nicpottier
Copy link

Though I do like the idea of it being automagic

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants