Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
node => {
if (node) {
assignRef(ref, node);
if (!bypass && node.textContent && domText !== node.textContent) {
setDomText(node.textContent);
}
}
},
[bypass, domText, ref]