easily-mongodb
v1.0.0
Published
![alt text](https://cdn.discordapp.com/attachments/947875178480807987/965672096149684274/Picsart_22-04-18_20-55-59-743.jpg)
Downloads
3
Readme
- Simple Package To Manage Data With MongoDB
- Install :
npm i easily-mongodb
Example :
- With Discord JS Library Example
- The Event Or Function Must Be Async
const db = require('easily-mongodb')
db.connect("Mongo Db Compass Url")
client.on('messageCreate' , async message => {
if(message.content === 'save') {
await db.set(`${message.author.id}`,true)
message.reply('data saved')
}
})
- Get Data
const db = require('easily-mongodb')
db.connect("Mongo Db Compass Url")
client.on('messageCreate', message => {
if(message.content === 'getdata') {
const data = db.get(`${message.author.id}`)
message.reply(data)
}
})