chalk / ansi-regex

Regular expression for matching ANSI escape codes
MIT License
182 stars 78 forks source link

'use strict', then use 'const', '=>' cause error in some browser #14

Closed addunt closed 7 years ago

addunt commented 7 years ago

'use strict', then use 'const', '=>' cause error in some browser

for example, in QQ mobile browser, shows error: 'Use of const in strict mode'

Qix- commented 7 years ago

You need to babel-ify your source base to ES5. const is a reserved keyword in Javascript < ES6.