map5
v1.0.5
Published
Map5 Map Systems
Downloads
3
Maintainers
Readme
Map5
Powerful Map System
Serverless
Lightning Fast
Simple
Completely JavaScript
Installation
$ npm i map5
$ yarn i map5
$ pnpm i map5
Usage
Basic Map:
const Map5 = require('map5')
const map = new Map5()
map.set('Password', '%9g4HVx^loX/')
map.get('Password')
//===> %9g4HVx^loX/
console.log(map.data())
//===> { Password: '%9g4HVx^loX/' }
Usage With JSON:
const Map5 = require('map5')
const map = new Map5()
map.set('The King', {
points: 9830,
XP: 734,
Coins: 530
})
map.set('The King', 748, 'XP')
//===> { points: 9830, XP: 748, Coins: 530 }
//===> Edit The King's XP
map.get('The King')
//===> { points: 9830, XP: 734, Coins: 530 }
console.log(map.data())
//===> { 'The King': { points: 9830, XP: 734, Coins: 530 }
Using In Multiple Files
Create A File Called Map5-Database.js
And Paste The Following Code Inside.
const Map5 = require('map5')
Map5.map = new Map5()
Then, You Can Require The Map In Another File:
const Map5 = require('map5')
const map = Map5.map
map.set('The King', 748, 'XP')
//===> { points: 9830, XP: 748, Coins: 530 }
//===> Edit The King's XP
map.get('The King')
//===> { points: 9830, XP: 734, Coins: 530 }
console.log(map.data())
//===> { 'The King': { points: 9830, XP: 734, Coins: 530 }
Map5™ © 2020 SliceWire Technologies Inc.
Power On.