initStorage() {
    if (storage) {
      return storage;
    }

    try {
      storage =
        typeof window !== 'undefined' && window !== null
          ? window.localStorage || window.sessionStorage
          : null;
    } catch (storageError) {
      storage = null;
    }

    if (!storage || this.isStorageDisabled(storage)) {
      storage = DEFAULT_STORAGE;
      storage.clear();
    }

    return storage;
  }
/**
   * Provides a singleton instance of the wrapped storage.
   * @return {Object}
   */
Provides a singleton instance of the wrapped storage.
@return {Object}
Provides a singleton instance of the wrapped storage . @return { Object }
initStorage() {
    if (storage) {
      return storage;
    }
    try {
      storage =
        typeof window !== 'undefined' && window !== null
          ? window.localStorage || window.sessionStorage
          : null;
    } catch (storageError) {
      storage = null;
    }
    if (!storage || this.isStorageDisabled(storage)) {
      storage = DEFAULT_STORAGE;
      storage.clear();
    }
    return storage;
  }
initStorage ( ) { if ( storage ) { return storage ; } try { storage = typeof window !== 'undefined' && window !== null ? window . localStorage || window . sessionStorage : null ; } catch ( storageError ) { storage = null ; } if ( ! storage || this . isStorageDisabled ( storage ) ) { storage = DEFAULT_STORAGE ; storage . clear ( ) ; } return storage ; }
Provides a singleton instance of the wrapped storage.
Provides a singleton instance of the wrapped storage .