hasItem(key)

Checks if items exists.

Arguments

  1. key (string): A string to find an item under.

Returns

(bool): true if item is found, false otherwise.

Example

// `result` will equal either `true` or `false` - depending if items exists or not
const result = adapter.hasItem('key');

Last updated