2013-10-16 62 views
1

我有NodeJS.express一個問題,當我通過創建一個新的包:快遞的NodeJS:#<Object>有沒有方法「解析」

express test_web 

它創建成功,但是當我打開localhost:3000主網頁,它不能訪問parse方法!

這是一個完整的網頁是什麼來:

Express 
500 TypeError: /Users/user/Documents/p/hello_test/views/index.jade:5 3| block content 4| h1= title > 5| p Welcome to #{title} Object #<Object> has no method 'parse' 
at detect (/Users/user/Documents/p/hello_test/node_modules/jade/node_modules/with/index.js:33:22) 
at addWith (/Users/user/Documents/p/hello_test/node_modules/jade/node_modules/with/index.js:8:28) 
at parse (/Users/user/Documents/p/hello_test/node_modules/jade/lib/jade.js:105:11) 
at Object.exports.compile (/Users/user/Documents/p/hello_test/node_modules/jade/lib/jade.js:142:9) 
at Object.exports.render (/Users/user/Documents/p/hello_test/node_modules/jade/lib/jade.js:196:15) 
at Object.exports.renderFile (/Users/user/Documents/p/hello_test/node_modules/jade/lib/jade.js:233:18) 
at View.exports.renderFile [as engine] (/Users/user/Documents/p/hello_test/node_modules/jade/lib/jade.js:218:21) 
at View.render (/Users/user/Documents/p/hello_test/node_modules/express/lib/view.js:76:8) 
at Function.app.render (/Users/user/Documents/p/hello_test/node_modules/express/lib/application.js:506:10) 
at ServerResponse.res.render (/Users/user/Documents/p/hello_test/node_modules/express/lib/response.js:803:7) 

我怎樣才能解決這個問題?

+0

你是否用'npm install -d'安裝了翡翠 – Plato

+0

是的,它已經安裝了。 – iOsam4h

+0

發佈您用於呈現網頁的代碼。 – hexacyanide

回答

相關問題