mongoose .connect( uri, { useNewUrlParser: true, useCreateIndex: true, useUnifiedTopology: true }) .then(() => console.log( 'Database Connected' )) .catch(err => console.log( err ));
并转到
MongoDB Atlas->
NetworkAccess->
Edit->并添加
Current IP address它!!
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)