createUtility
Element type.
The function to be executed.
A utility function that processes the element.
Creates a utility function that enqueues a function to be executed on the next tick. Useful for batching updates to avoid layout thrashing.
const delayedUpdate = createUtility<HTMLDivElement>((el) => { el.style.color = "blue"; return el;}); Copy
const delayedUpdate = createUtility<HTMLDivElement>((el) => { el.style.color = "blue"; return el;});
createUtility