https://github.com/wangdahoo/storage-js-iso
storage.js compatible with isomorphic apps.
https://github.com/wangdahoo/storage-js-iso
Last synced: 11 months ago
JSON representation
storage.js compatible with isomorphic apps.
- Host: GitHub
- URL: https://github.com/wangdahoo/storage-js-iso
- Owner: wangdahoo
- Created: 2017-03-31T18:07:28.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2021-08-11T04:04:23.000Z (almost 5 years ago)
- Last Synced: 2025-04-05T15:46:32.669Z (about 1 year ago)
- Language: JavaScript
- Size: 129 KB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# storage-js-iso
storage.js compatible with isomorphic apps.
### How to use
```html
```
```js
$storage.on('time', function (e) {
console.log('time changed', e)
})
setInterval(function () {
$storage.set('time', (new Date()).getTime());
}, 50)
```
### API
- set(key:String, value:Any)
- get(key:String)
- remove(key:String)
- clear()
- on(key:String, fn:Function)
- off(key:String, fn:Function)