
committed by
Alex Rickabaugh

parent
f455518d80
commit
9993c72335
@ -74,8 +74,8 @@ export function createCustomEvent(doc: Document, name: string, detail: any): Cus
|
||||
/**
|
||||
* Check whether the input is an `Element`.
|
||||
*/
|
||||
export function isElement(node: Node): node is Element {
|
||||
return node.nodeType === Node.ELEMENT_NODE;
|
||||
export function isElement(node: Node | null): node is Element {
|
||||
return !!node && node.nodeType === Node.ELEMENT_NODE;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user