From d43810cd310594267848506c131afa24549067a9 Mon Sep 17 00:00:00 2001 From: Guillaume REMY Date: Thu, 9 Jan 2025 21:02:29 +0100 Subject: [PATCH] Simplify destructuring code so that Typescript understands it --- esm/dom/utils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/esm/dom/utils.js b/esm/dom/utils.js index 1f102f3..abba346 100644 --- a/esm/dom/utils.js +++ b/esm/dom/utils.js @@ -4,7 +4,7 @@ import { childNodes, nodeType, parentNode } from './symbols.js'; import { empty } from '../utils.js'; -export const asElement = ({ [nodeType]: type }) => type === ELEMENT_NODE; +export const asElement = (obj) => obj[nodeType] === ELEMENT_NODE; export const changeParentNode = (node, parent) => { if (node[nodeType] === DOCUMENT_FRAGMENT_NODE)