import { CacheContainer } from './interface' ; class LocalStorage implements CacheContainer { getItem ( key ) { return window . localStorage . getItem ( key ) ; } setItem ( key , value ) { window . localStorage . setItem ( key , value ) ; } } let storage = new LocalStorage ( ) ; export const setCacheContainer = ( cacheContainer ) => { storage = cacheContainer ; } ; export const setCacheLink = ( storageKey , depLink ) => { storage . setItem ( storageKey , depLink ) ; } ; export const getCacheLink = ( storageKey ) => storage . getItem ( storageKey ) ;