Help us shape the future of Go! Take the 2026 Go Developer Survey

rule

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TableRowSeparators added in v0.7.0

func TableRowSeparators(row []byte) []int

TableRowSeparators returns the offsets of the '|' characters of a table row that separate cells; a '|' inside a code span or a {{ }} unit is not a separator.

Types

type LineRemover added in v0.7.0

type LineRemover interface {
	RemovedLines(source []byte) [][2]int
}

LineRemover is implemented by rules whose source has lines that are removed before it is parsed. The parser parses the source without the returned [start, end) ranges, and node ranges still refer to the original source.

type Rule

type Rule interface {
	Name() string
	Selectors() []selector.Selector
	Rules() []Rule
}

func NewDynamic

func NewDynamic(name string) Rule

func NewGlobalCompDef

func NewGlobalCompDef() Rule

func NewGlobalCompDefHead

func NewGlobalCompDefHead() Rule

func NewGlobalCompDefWrapper

func NewGlobalCompDefWrapper() Rule

func NewGlobalCompName

func NewGlobalCompName() Rule

func NewRoot

func NewRoot() Rule

Jump to

Keyboard shortcuts

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