rawparse

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package rawparse provides the lossless dummy format parser used to exercise the shared template parser without HTML or SQL knowledge.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Parse

func Parse(filename string, source []byte) (*syntax.Module, error)

Parse uses a generic template declaration so shared parser fixtures do not depend on component/HTML or statement/SQL behavior.

func Root

func Root(keyword, nodeType, outputPrefix string) syntax.RootDeclaration

Root creates a configurable root declaration backed by the dummy parser.

Types

type Parser

type Parser struct{}

func (Parser) ParseBody

func (Parser) ParseBody(context *syntax.BodyContext, insertionContext string) ([]syntax.Node, *syntax.Terminator, error)

type TextNode

type TextNode struct {
	Kind string          `json:"kind"`
	Pos  syntax.Position `json:"pos"`
	Text string          `json:"text"`
}

func (*TextNode) NodeType

func (n *TextNode) NodeType() string

Jump to

Keyboard shortcuts

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