tiptap/packages/core/src/utilities/removeElement.ts

6 lines
151 B
TypeScript
Raw Normal View History

2020-03-31 19:06:34 +08:00
export default function removeElement(element: HTMLElement) {
if (element && element.parentNode) {
element.parentNode.removeChild(element)
}
2020-09-24 06:29:05 +08:00
}