咖啡+ Express:意想不到的,
我正在学习使用Coffeescript在Express.js上创build一个应用程序。 我上传了我的代码: https : //github.com/findjashua/contactlist
当我尝试运行该应用程序时,出现以下错误:
app.coffee:11:24: error: unexpected , res.send 'Hello World' ^
我不明白这个问题。 有任何想法吗?
在你有contacts.coffee的第11行
exports.index = (req, res) -> ContactModel.find (err, contacts), -> if not err
删除中心线上的逗号, contacts)
后contacts)
。