官术网_书友最值得收藏!

Adding the application code

Now, let's write the simple application code to test things out. This app is going to basically connect to our locally running MongoDB server, insert a few records as seed data, and then provide the output on whether or not the data was inserted properly into MongoDB. You can download a Gist of the code via this URL: http://bit.ly/1JpT8QL.

Using your editor of choice, create a new file named app.js and save it to the application root, which is the testapp folder. Just copy the content of the preceding Gist on to the app.js file.

主站蜘蛛池模板: 光山县| 花莲市| 台南市| 喀什市| 镇巴县| 普安县| 西林县| 上栗县| 桃园市| 钟祥市| 霍林郭勒市| 松阳县| 蕲春县| 江孜县| 青阳县| 汤阴县| 新营市| 张家港市| 隆德县| 阿拉善左旗| 井研县| 临泽县| 阿鲁科尔沁旗| 县级市| 疏附县| 桐乡市| 同江市| 稻城县| 视频| 台南市| 聊城市| 资兴市| 宜君县| 建阳市| 西丰县| 镇沅| 新绛县| 馆陶县| 阿勒泰市| 三明市| 比如县|