Node.js is a platform built on the Chrome JavaScript runtime.

Node.js is an event-driven I/O server-side JavaScript environment based on Google's V8 engine. The V8 engine executes Javascript very quickly and has very good performance.

Node.js connects to MongoDB syntax

MongoDB is a document-oriented database management system written in C.

Node.js connects to MongoDB example

var MongoClient = require('mongodb').MongoClient; var url = "mongodb://localhost:27017/runoob"; MongoClient.connect(url, function(err, db) { if (err) throw err; console.log("数据库已创建!"); db.close();});