The DOM element or selector of the DOM element to modify.
The new attributes to set to the DOM element.
The modified DOM element.
import { modifyElement } from '@untemps/utils/dom/modifyElement'const element = document.createElement('div')element.className = 'foo'document.body.appendChild(element)modifyElement(element, { className: 'bar' }) // <div class="bar"></div> Copy
import { modifyElement } from '@untemps/utils/dom/modifyElement'const element = document.createElement('div')element.className = 'foo'document.body.appendChild(element)modifyElement(element, { className: 'bar' }) // <div class="bar"></div>
The DOM element or selector of the DOM element to modify.