Added indexdb wrapper & cache support for it
This commit is contained in:
15
index.html
Normal file
15
index.html
Normal file
@ -0,0 +1,15 @@
|
||||
<html>
|
||||
<body>
|
||||
<script type="module">
|
||||
import {Cache, Collection} from './dist/index.mjs';
|
||||
|
||||
const cache = new Cache('id', {
|
||||
ttl: 60,
|
||||
storage: new Collection('test', 'test'),
|
||||
expiryPolicy: 'delete'
|
||||
});
|
||||
|
||||
cache.add({id: 1, name: 'zak', age: 27});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user