getExtra(key)

Returns and extra.

Arguments

  1. key (string): A string used to find and fetch item's extra under.

Returns

(object): The extra part of Item.

(undefined): If item is not found (thus no extra can be taken from it), returns undefined.

Example

// `extra` will be either an object or undefined - depending if item exists or not
const extra = adapter.getExtra('key');

Last updated