tc39 / proposal-template-literal-revision

https://tc39.github.io/proposal-template-literal-revision/
37 stars 8 forks source link

Is that proposal still work? #11

Closed aleen42 closed 5 years ago

aleen42 commented 5 years ago

Recently, I have found that this proposal has reached stage 4, but I found that most browsers does not still lift such a template literal restriction, and I want to know is the proposal still work?

trotyl commented 5 years ago

Have you checked https://github.com/tc39/proposal-template-literal-revision/issues/5? All browsers except Edge have land it, can also be found in compat-table.

aleen42 commented 5 years ago

image

Maybe the checked list does not matters, as I have checked that Chrome still has the restriction.

trotyl commented 5 years ago

This loosening of the escape sequence restriction only applies to tagged template literals; untagged templates still throw an early error for invalid escape sequences:

let bad = `bad escape sequence: \unicode`; // throws early error

aleen42 commented 5 years ago

OK, I need to check the usage of tag`literal`