const MongoClient = require('mongodb').MongoClient; const url = 'mongodb://localhost:27017/User'; MongoClient.connect(url, (err, client) => { if (err) throw err; console.log('Database created!'); client.close(); })