instance method Element#retrieve

View source on GitHub →

Element#retrieve(key[, defaultValue]) → ?

Retrieves custom metadata set on element with

If the value is undefined and defaultValue is given, it will be stored on the element as its new value for that key, then returned.

This method can be called either as an instance method or as a generic method. If calling as a generic, pass the instance in as the first argument.