collapse

package
v1.0.0-alpha.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 26, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

collapse can collapse whitespace in html elements.

It is a port from the Javascript library "turndown" to Golang.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Collapse

func Collapse(element *html.Node, domFuncs *DomFuncs)

Types

type DomFuncs

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

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL