-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add functions to avoid stringifying HTML in translations with tokens
When replacing tokens in a formatted string (which is often a translated string), it's problematic if the replacements include HTML, because then it has to be a string instead of a React element, which leads to using things like RawHTML. This adds some helper functions that handle things as arrays instead of strings so that they can be manipulated and added as child elements in React templates.
- Loading branch information
1 parent
1c7e242
commit bbe3ce8
Showing
2 changed files
with
189 additions
and
76 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters