# Storage.setItem method

    setItem(
      key: string,
      value: string
    ): void;

Sets the value of the pair identified by key to value, creating a new key-value
pair if none existed for key previously.

## Examples

    // User earns a new star.
    starsEarned++;

    GameSnacks.storage.setItem('starsEarned', starsEarned.toString());