INNER CODE UNIT · Go

removeNode

JohannesKaufmann/html-to-markdown · collapse/collapse.go:72

func removeNode(node *html.Node) *html.Node {
	next := node.NextSibling
	if next == nil {
		next = node.Parent
	}

	node.Parent.RemoveChild(node)

	return next

}

type DomFuncs struct {
	IsBlockNode        func(node *html.Node) bool
	IsVoidNode         func(node *html.Node) bool
	IsPreformattedNode func(node *html.Node) bool
}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…