Store arbitrary data associated with the es6 weekman and/or return the value that was set.
1. Install from Npm
npm install lonly-cachejs
2. Import from node_modules
import { CacheJS } from 'lonly-cashjs'
3. Store or get data
Add Data
let tester = {}
CacheJS.addData(tester, 'name', 'lonly') // return Map
Get Data
CacheJS.getData(tester, 'name') // return String
CacheJS
|
|__addData(owner, name, data)
|
|__getData(owner, name)
|
|__removeData(owner, name)
|
|__clearData