Versions in this module Expand all Collapse all v0 v0.1.0 Aug 29, 2026 Changes in this version + func Materialize(source []byte) ([]byte, error) + func NewID() (string, error) + func NormalizedXML(document Document) ([]byte, error) + func Strip(source []byte) []byte + type Atom struct + Attributes []Attribute + Content Range + GroupID string + ID string + Implicit bool + Marker *Range + NodeType string + Slug string + Text string + type AtomGroup struct + AtomIDs []string + Attributes []Attribute + EndMarker *Range + ID string + Marker Range + Slug string + type Attribute struct + Name string + Value string + type Diagnostic struct + Code string + Fix string + Message string + Position Position + Severity Severity + type DirectiveToken struct + Attributes []Attribute + Element string + ID string + Operation string + Slug string + Version string + type Document struct + Atoms []Atom + Attributes []Attribute + Declared bool + Diagnostics []Diagnostic + Groups []AtomGroup + Version string + func Parse(source []byte) Document + func (d Document) HasErrors() bool + type Extension interface + Name func() string + Transform func(context.Context, []byte, *Document) error + type ExtensionFunc struct + ExtensionName string + TransformFunc func(context.Context, []byte, *Document) error + func (extension ExtensionFunc) Name() string + func (extension ExtensionFunc) Transform(ctx context.Context, source []byte, document *Document) error + type Position struct + Column int + Line int + Offset int + type Processor struct + func NewProcessor(extensions ...Extension) *Processor + func (processor *Processor) Process(ctx context.Context, source []byte) (Document, error) + type Range struct + End Position + Start Position + type Severity string + const SeverityError + const SeverityWarning + type Token struct + Directive *DirectiveToken + Kind TokenKind + NodeType string + Range Range + Raw string + type TokenKind string + const TokenDirective + const TokenMarkdown + const TokenWhitespace + type TokenStream struct + Diagnostics []Diagnostic + Tokens []Token + func Tokenize(source []byte) TokenStream