Database
We use enmap to connect to your mongo database as it is fast and easy to use. Because of deprecation we use enmap 3 and enmap-mongo.
// 1
const database = require("js-spring").database;
// 2
const { database } new SpringJS({ name: "test" });Example usage
const SpringJS = require("js-spring");
const { database } new SpringJS({ name: "test" });
database.set("DanCodes", "Spring.js");
console.log("DanCodes wrote " + database.get("DanCodes") + "!");Last updated
Was this helpful?