How to debug Mongoose and MongoDB in a MEAN stack?

2019-03-01 02:10发布

I'm learning the MEAN stack and I'm using npm start to run my application. I have some issues with Mongoose and MongoDB but all I get is POST /page 500 63.925 ms - 961

This is the directory structure of my app, based on this tutorial:

HTML        views/
Angular.js  public/javascript/
Express.js  routes/
Node.js     app.js
Mongoose js models/, connected in app.js
Mongo db    connected in app.js

What can I do to get helpful Mongoose and MongDB debug messages?

1条回答
The star\"
2楼-- · 2019-03-01 02:45

Using node-inspector is very helpful. This question and answer showed me how to set it up in my case.

查看更多
登录 后发表回答