slimit
slimit copied to clipboard
Unexpected token (DELETE, 'delete')
I've the following error when I'm trying to parse a file:
Unexpected token (DELETE, 'delete') at 1:25116 between LexToken(PERIOD,'.',1,25115) and LexToken(EQ,'=',1,25123)
It happens with this part of code:
if (arch) {
this.activeActions.create = arch.attrs.create ?
JSON.parse(arch.attrs.create) :
true;
this.activeActions.delete = arch.attrs.delete ?
JSON.parse(arch.attrs.delete) :
true;
this.editable = arch.attrs.editable;
}
Same issue as #52, #59, #103.
If you are having continuous issue with this library (as you have reported a number of issues recently here), and if you want a similar ES5 parser but one that is actually maintained with bugs fixed to conform as much as possible to the ECMA-252 5.1 spec, please consider giving the forked project calmjs.parse
a try, I will generally respond much quicker to issues than the maintainer for this project.