Template Literals非常强大
Template Literals
,也就是模板字面量
,非常强大,对于操作字符串,非常有用,至少解决了ES5
没有解决的3个问题:
- Multiline strings A formal concept of multiline strings.
- Basic string formatting The ability to substitute parts of the string for values contained in variables.
- HTML escaping The ability to transform a string such that it is safe to insert into HTML.