I came across with parsing error
Is it because of content
property value?
I came across with parsing error
Is it because of content
property value?
The problem is the backslash. You need two backslashes to represent a backslash within an HTML or Markdown tagged template literal because a single backslash is reserved for Unicode escape sequences (e.g., \u00A9
).
Try \\25B6
instead of \25B6
.
Previously, this was a syntax error⌠and it still is if you use an untagged template literal. If you try this, youâll see a SyntaxError: Bad escape sequence in untagged template literal.
`bad escape sequence: \unicode`
Possibly our tagged template literals should throw a SyntaxError in this case.