Wrapper for LocalStorage.

Constructors

Methods

Constructors

  • Returns Storage

Methods

  • Removes the item from the storage.

    Parameters

    • key: string

      Key of the item in the storage.

    Returns void

  • Gets the data from the storage.

    Type Parameters

    • T = any

    Parameters

    • key: string

      Key of the item in the storage.

    Returns T

    T Type of the returned data.

  • Checks if the storage has the key.

    Parameters

    • key: string

      Key of the item in the storage.

    Returns boolean

  • Sets the data to the key.

    Parameters

    • key: string

      Key of the item in the storage.

    • data: any

      Data to save.

    Returns void