Skip to content
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

Improve localized texts rendering #157

Open
tanelj opened this issue Jul 5, 2019 · 0 comments
Open

Improve localized texts rendering #157

tanelj opened this issue Jul 5, 2019 · 0 comments
Labels

Comments

@tanelj
Copy link
Member

tanelj commented Jul 5, 2019

When localized text (lc filter) are rendered to template as JS values then it should be escaped.

Example:

site.bindContentItemImgDropAreas('{{ "drag_picture_for_product_here" | lc: editor_locale }}');

If FR:

site.bindContentItemImgDropAreas('Faites glisser l'image d'un produit ici à partir du paneau "Fichiers".');

Possible fix:

site.bindContentItemImgDropAreas('{{ "drag_picture_for_product_here" | lc: editor_locale | json }}');
@tanelj tanelj added the bug label Jul 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant