Function createAfter

Creates an element after sibling

const el = createAfter(siblingEl, `DIV`);
  • Parameters

    • sibling: Readonly<HTMLElement>

      Element

    • tagName: string

      Element to create

    Returns HTMLElement

    New element