Function: hasInterface()
hasInterface<
E,K>(element,key):element is E & ElementInterfaces[K]
Narrows an element to an interface it lists in provides.
Type Parameters
E
E extends BaseElement
K
K extends keyof ElementInterfaces
Parameters
element
E
key
K
Returns
element is E & ElementInterfaces[K]