I am optimizing several js files into one using r.js
. It works fine before. Recently,I modified some js code, add the code as:
var x = 08;
then it shows
ERROR:parse error using esprima for file D://webroot/js/a.js
ERROR:line 45: Unexpected token ILLEGAL.
Line 45 is where I add var x = 08
, and 09
will show error too. It seemed that numbers begining with 0 meanwhile containing 8
or 9
is illegal. Maybe they were treated as bese 8 number .. ?
How can I let r.js
ignore this point and still optimizie js files?