docs(regex): edit regex

This commit is contained in:
ruanyf
2018-01-25 15:54:17 +08:00
parent ee982c4314
commit 6097cc302f
3 changed files with 74 additions and 10 deletions
+4
View File
@@ -349,6 +349,10 @@ ES2017 引入了字符串补全长度的功能。如果某个字符串不够指
'09-12'.padStart(10, 'YYYY-MM-DD') // "YYYY-09-12"
```
## matchAll()
`matchAll`方法返回一个正则表达式在当前字符串的所有匹配,详见《正则的扩展》的一章。
## 模板字符串
传统的 JavaScript 语言,输出模板通常是这样写的。