chrome_extension_storage
v0.9.2
Published
A simple encapsulation for manipulating the storage API when develops a Chrome extension.
Downloads
3
Readme
Introduction
This is a simple encapsulation for manipulating the storage API when develops a Chrome extension.
The API follows the interfaces of chrome storage, but provides the feature of setting expires.
An Usage Example
import ChromeStorage from 'chrome_extension_storage';
const storage = new ChromeStorage();
storage.set({
testKey: 'testValue',
testKey2: 'testValue2',
});
storage.get('testKey').then((value) => {
assert(value.testKey === 'testValue');
assert(value.testKey2 === 'testValue2');
});