Polyfill for
void ChildNode.replaceWith((Node or DOMString)... nodes);
This the npm module version of polyfill found here: https://developer.mozilla.org/en-US/docs/Web/API/ChildNode/replaceWith so that it is easier to integrate to regular projects
npm install --save child-replace-with-polyfill
import "child-replace-with-polyfill";
or
require("child-replace-with-polyfill");
I dont think this polyfill would need any more maintainence but feel free to raise a PR if needed