求助:nodejs运行网页访问抛出错误error at new js_parse_error
发布于 18天前 作者 Mecil9 145 次浏览 来自 问答

server已经运行起来,但是浏览器登陆后页面抛出下面的错误,请问问这是什么原因造成的?

Error
at new JS_Parse_Error (/Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:189:18)
at js_error (/Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:197:11)
at croak (/Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:661:41)
at token_error (/Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:665:9)
at unexpected (/Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:671:9)
at /Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:831:17
at /Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:704:24
at block_ (/Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:978:20)
at /Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:951:25
at function_ (/Users/Janet/Node/microblog/node_modules/jade/node_modules/with/node_modules/uglify-js/lib/parse.js:956:15)
4 回复

看代码是用uglify去压缩js代码吧,js代码里有语法错误。

感觉奇怪, UglifyJS 抛的错误不应该只有这么点啊…

回到顶部