GitHub 6248★

Insert given HTML after an element

JavaScript version

const insertHtmlAfter = (html, ele) => ele.insertAdjacentHTML('afterend', html);

TypeScript version

const insertHtmlAfter = (html: string, ele: Element): void => ele.insertAdjacentHTML('afterend', html);
Follow me on and to get more useful contents.