web/src/utils/storage.ts

8 lines
332 B
TypeScript
Raw Normal View History

import BaseStorage from './storage/BaseStorage';
import BrowserNativeStorage from './storage/BrowserNativeStorage';
import ChromeExtensionStorage from './storage/ChromeExtensionStorage';
const storage: BaseStorage = ChromeExtensionStorage.works ? new ChromeExtensionStorage() : new BrowserNativeStorage();
export default storage;