猿问

nodejs 点击链接报错

Error: Failed to lookup view "error" in views directory "D:\workspace\javascript\nodes\demo1\views"
   at EventEmitter.render (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\application.js:579:17)
   at ServerResponse.render (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\response.js:961:7)
   at D:\workspace\javascript\nodes\demo1\app.js:61:7
   at Layer.handle_error (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\router\layer.js:71:5)
   at trim_prefix (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\router\index.js:310:13)
   at D:\workspace\javascript\nodes\demo1\node_modules\express\lib\router\index.js:280:7
   at Function.process_params (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\router\index.js:330:12)
   at IncomingMessage.next (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\router\index.js:271:10)
   at done (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\response.js:956:25)
   at EventEmitter.render (D:\workspace\javascript\nodes\demo1\node_modules\express\lib\application.js:581:14)

Micity
浏览 1733回答 1
1回答

Salettre

错误提示在第6行  at D:\workspace\javascript\nodes\demo1\app.js:61:7,初步判断应该是你设置了错误时提示的页面,但你的view目录下没有error.jade或者error.html,你可以去view目录看看
随时随地看视频慕课网APP

相关分类

Node.js
我要回答