compiler

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2026 License: MIT Imports: 39 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package compiler parses .gx files into an AST. The AST is the input of the formatter, the type checker and the code generator.

Index

Constants

View Source
const (
	CodeParse    = "GX1000"
	CodeFileName = "GX1001"
	CodeStale    = "GX1002"

	CodeRouteField = "GX3000"
	CodePathVar    = "GX3001"
	CodePathField  = "GX3002"
	CodeUnmounted  = "GX3003"
	CodeDuplicate  = "GX3004"
	CodeRoutePkg   = "GX3005"

	CodeRequiredProp     = "GX2001"
	CodeUnknownComponent = "GX2002"
	CodeUnknownAttr      = "GX2003"
	CodeStaticStringProp = "GX2004"

	CodeType = "GX2000"

	CodeSpread        = "GX2005"
	CodeDuplicateSlot = "GX2006"
	CodeEventAttr     = "GX2007"
	CodeFragment      = "GX2008"
	CodeLoopKey       = "GX2009"
	CodeSignal        = "GX2010"
	CodeURLAttr       = "GX2011"
	CodeUnrenderable  = "GX2013"

	CodeTrustedHTML = "GX7001"
	CodeSecret      = "GX7002"

	CodeEnum = "GX5001"

	CodeTransition = "GX5002"

	CodeRuntimeClass = "GX5003"

	CodeContentFrontmatter = "GX8001"

	CodeContentComponent = "GX8002"

	CodeContentLink = "GX8003"

	CodeCodeFile = "GX8004"

	CodeActionMissing       = "GX4001"
	CodeActionTwice         = "GX4002"
	CodeActionMissingSignal = "GX4003"
	CodeSignalTypeMismatch  = "GX4004"
	CodeClientCall          = "GX4005"
	CodeAdapterSignals      = "GX4006"
	CodeClientType          = "GX4007"
	CodeInstanceKey         = "GX2012"
	CodeSignalDefault       = "GX2014"
	CodeSignalRoot          = "GX2015"
	CodeEventMod            = "GX4010"
	CodeActionMethod        = "GX4009"
	CodeSignalRules         = "GX4008"

	CodeIslandProps = "GX6001"
	CodeIslandType  = "GX6002"
	CodeIslandLoad  = "GX6004"
	// CodeIslandTypeScript is one error of the TypeScript compiler in an
	// island file (REQ-ISL-08).
	CodeIslandTypeScript = "GX6005"
)

Diagnostic codes. Every code is stable and has a docs page (REQ-AUT-19).

View Source
const (
	ElementString = "string"
	ElementBool   = "bool"
	ElementNumber = "number"
	// ElementEnum is a string with a fixed set of values.
	ElementEnum = "enum"
)

The kinds of an element attribute.

View Source
const ElementsFile = "gx-elements.json"

ElementsFile is the file that describes the imported web components of a package (REQ-ISL-09). `gx wc pin` writes it from the custom elements manifest of an npm package.

Variables

View Source
var Catalog = []Info{
	{CodeParse, "parse error"},
	{CodeFileName, "component file name is not an exported identifier"},
	{CodeStale, "generated code is missing or stale"},
	{CodeType, "type error in an expression"},
	{CodeRequiredProp, "missing required prop"},
	{CodeUnknownComponent, "unknown component"},
	{CodeUnknownAttr, "unknown attribute or slot"},
	{CodeStaticStringProp, "static value for a typed prop"},
	{CodeSpread, "attribute spread on a component"},
	{CodeDuplicateSlot, "duplicate slot"},
	{CodeEventAttr, "dynamic event attribute"},
	{CodeFragment, "fragment free variable"},
	{CodeLoopKey, "loop needs a key"},
	{CodeSignal, "signal in a server expression"},
	{CodeInstanceKey, "signal instance needs a key"},
	{CodeSignalDefault, "signal needs an initial value"},
	{CodeSignalRoot, "component with signals has no top-level HTML element"},
	{CodeURLAttr, "dynamic URL attribute"},
	{CodeUnrenderable, "value cannot render as text"},
	{CodeRouteField, "route field type cannot bind"},
	{CodePathVar, "pattern variable has no field"},
	{CodePathField, "path field has no pattern variable"},
	{CodeUnmounted, "route value is not held by any gx.Collect"},
	{CodeDuplicate, "duplicate route pattern"},
	{CodeRoutePkg, "route package contents"},
	{CodeActionMissing, "no action is registered for a route type"},
	{CodeActionTwice, "more than one action is registered for a route type"},
	{CodeActionMissingSignal, "no signal is declared for a signal-bound field"},
	{CodeSignalTypeMismatch, "signal type does not match the action field"},
	{CodeClientCall, "call is not allowed in a client expression"},
	{CodeAdapterSignals, "signal or client expression under an adapter with no signals"},
	{CodeClientType, "value or operator is not allowed in a client expression"},
	{CodeSignalRules, "signal-bound fields need rules or gx.Unchecked"},
	{CodeActionMethod, "action method cannot be invoked from the client"},
	{CodeEventMod, "unknown event modifier or special event"},
	{CodeEnum, "gx.Enum misses a constant of its type"},
	{CodeTransition, "duplicate view-transition-name in one template"},
	{CodeRuntimeClass, "class string is built at runtime"},
	{CodeIslandProps, "island has no props struct"},
	{CodeIslandType, "island prop type has no TypeScript mapping"},
	{CodeIslandLoad, "unknown island load strategy"},
	{CodeIslandTypeScript, "TypeScript error in an island"},
	{CodeTrustedHTML, "conversion to gx.SafeHTML needs //gx:trusted"},
	{CodeSecret, "gx.Secret cannot cross to the client"},
	{CodeContentFrontmatter, "frontmatter is malformed or unknown"},
	{CodeContentComponent, "component is not declared in this collection"},
	{CodeContentLink, "content link or anchor is broken"},
	{CodeCodeFile, "code file or line range is missing"},
}

Catalog lists every diagnostic code (REQ-AUT-19). Keep it in step with the code constants above; the catalog test fails when it does not.

View Source
var DescribeSchema []byte

DescribeSchema is the JSON Schema of AppModel. `gx describe --schema` prints it.

Functions

func ClassesPath added in v0.2.0

func ClassesPath(root string) string

ClassesPath returns the path of the generated class list of the app at root. The stylesheet build reads it.

func Describe

func Describe(root string) (*AppModel, []Diagnostic)

Describe returns the app model of the module under root (REQ-AI-01).

func ElementModules added in v0.2.0

func ElementModules(root string) []string

ElementModules returns the modules of the imported elements that the .gx files under root use, in order (REQ-ISL-09). The island bundler makes one entry file for each.

func FileSignature added in v0.2.0

func FileSignature(path string) (string, bool)

FileSignature returns the part of a .gx file that other code depends on: the package, the imports, the props, the signals and the fragment parameters. A change that keeps it is a change of markup only, which the dev server can swap into the running app (REQ-DEV-02).

func Format

func Format(f *File) []byte

Format returns the canonical source of f (REQ-AUT-17).

func ImportPath

func ImportPath(raw string) string

ImportPath returns the path of an import spec as written, without the alias and quotes (REQ-DEV-08).

func ImportQualifier

func ImportQualifier(raw string) string

ImportQualifier returns the name an import spec is used by. An import without an alias uses the last path segment.

func PackagePath added in v0.2.0

func PackagePath(dir string) string

PackagePath returns the import path of the Go package in dir, or "".

func ParseFile

func ParseFile(file string, src []byte) (*File, []Diagnostic)

ParseFile parses a .gx file. file may be empty for input with no file name, such as stdin; the component name check is then skipped.

func ParseFragment

func ParseFragment(src []byte) (*File, []Diagnostic)

ParseFragment parses markup with no package clause, imports, props or signals. It is used by the HTML corpus tests.

func Quoted

func Quoted(s string) string

Quoted returns s as a double-quoted Go string.

func Routes

func Routes(root string) ([]RouteReport, []Diagnostic)

Routes reports every route of the module under root.

Types

type ActionModel

type ActionModel struct {
	Handler string `json:"handler"`
	Route   string `json:"route"`
	Method  string `json:"method"`
	Pattern string `json:"pattern"`
	// Signals lists the signal names the action reads.
	Signals []string `json:"signals"`
	// External is true when another server answers the action.
	External bool `json:"external"`
}

ActionModel is one gx.Action.

type AppModel

type AppModel struct {
	Module      string            `json:"module"`
	Components  []ComponentModel  `json:"components"`
	Routes      []RouteModel      `json:"routes"`
	Actions     []ActionModel     `json:"actions"`
	Forms       []FormModel       `json:"forms"`
	Islands     []IslandModel     `json:"islands"`
	Elements    []ElementModel    `json:"elements"`
	Transitions []TransitionModel `json:"transitions"`
	Icons       []IconSetModel    `json:"icons"`
	Registry    []RegistryModel   `json:"registry"`
}

AppModel is the machine-readable model of an app (REQ-AI-01). `gx describe --json` prints it and the dev MCP server answers with it. The CLI adds the icon sets and the registry items from gx.lock.

type Attr

type Attr struct {
	At      Pos
	Kind    AttrKind
	Name    string
	Value   string
	ValueAt Pos
}

Attr is one attribute of an element.

func (*Attr) Position

func (a *Attr) Position() Pos

type AttrKind

type AttrKind int

AttrKind tells how an attribute value is written.

const (
	AttrBool AttrKind = iota
	AttrString
	AttrExpr
	AttrSpread
	AttrFragment
)

type Case

type Case struct {
	At        Pos
	Header    string
	IsDefault bool
	Body      []Node
}

Case is one switch clause.

type CheckOptions

type CheckOptions struct {
	// ExternalLinks requests every external content link.
	ExternalLinks bool
	// Client is the HTTP client of the external check.
	Client *http.Client
	// Adapter checks the files for this adapter and not for the adapter
	// key of gx.toml (REQ-ACT-09). The registry has no gx.toml, and its
	// items must compile for each adapter.
	Adapter string
}

CheckOptions configure one check (REQ-CNT-10).

type CollectionRef

type CollectionRef struct {
	Dir        string
	Components []ContentComponent
}

CollectionRef is one gx.Collection declaration (REQ-CNT-03).

type Comment

type Comment struct {
	At   Pos
	Data string
}

Comment is a {/* ... */} comment. It never renders.

func (*Comment) Position

func (n *Comment) Position() Pos

type Component

type Component struct {
	Name  string
	File  *File
	Props []Prop
	// Island is set when the component is a TypeScript island. File is then
	// an empty file that names the .ts source.
	Island *Island
}

Component is one component definition.

type ComponentModel

type ComponentModel struct {
	Name      string          `json:"name"`
	Package   string          `json:"package"`
	File      string          `json:"file"`
	Props     []PropModel     `json:"props"`
	Signals   []SignalModel   `json:"signals"`
	Fragments []FragmentModel `json:"fragments"`
	// Fixtures holds the fixture names of the component, in order.
	Fixtures []string `json:"fixtures"`
}

ComponentModel is one .gx component.

type ComponentRef

type ComponentRef struct {
	Name    string
	Dir     string
	PkgPath string
	File    *File
	Props   []Prop
}

ComponentRef is one component of the module (REQ-DEV-08).

type ContentComponent

type ContentComponent struct {
	Name  string
	Props []Prop
}

ContentComponent is one component a collection allows in its Markdown files.

type Control

type Control struct {
	At     Pos
	Kind   string
	Header string
	Body   []Node
	Else   []Node
	Cases  []Case
}

Control is an if, for or switch block.

func (*Control) Position

func (n *Control) Position() Pos

type Diagnostic

type Diagnostic struct {
	Code string
	File string
	Line int
	Col  int
	Msg  string
	Fix  string
}

Diagnostic is one compiler message.

func Check

func Check(root string) []Diagnostic

Check checks every .gx package under root and returns the diagnostics, ordered by file, line and column. It checks props and components, then type-checks every server expression.

func CheckApp

func CheckApp(root string, opt CheckOptions) []Diagnostic

CheckApp is the whole check of an app, as `gx check` runs it: every diagnostic of CheckWith, the diagnostics that only the generator can give, and a GX1002 for each generated file that is missing or stale. A diagnostic that both passes find is reported once.

The check and the generator share one analysis: the generator starts with the same steps as CheckWith, so a second analysis finds nothing new and takes as long as the first (NFR-05).

func CheckWith

func CheckWith(root string, opt CheckOptions) []Diagnostic

CheckWith checks a module with options (REQ-CNT-10).

func FormatSource

func FormatSource(file string, src []byte) ([]byte, []Diagnostic)

FormatSource parses src and returns its canonical form (REQ-AUT-17). It returns the parse diagnostics instead when src does not parse.

func Generate

func Generate(root string) (map[string][]byte, []Diagnostic)

Generate generates Go source for every .gx file under root. The result maps each generated file path to its source. It returns diagnostics instead when any check fails.

func Stale

func Stale(root string) []Diagnostic

Stale returns GX1002 for every .gx file whose generated file is missing or out of date (REQ-AUT-18).

func (Diagnostic) Doc

func (d Diagnostic) Doc() string

Doc returns the documentation path of the diagnostic (REQ-AUT-19).

func (Diagnostic) String

func (d Diagnostic) String() string

type Element

type Element struct {
	At        Pos
	Name      string
	Attrs     []Attr
	Children  []Node
	RawText   string
	HasRaw    bool
	SelfClose bool
	// contains filtered or unexported fields
}

Element is an HTML element, a component tag or a slot.

func Fragments

func Fragments(f *File) []*Element

Fragments returns the fragment elements of a component body (REQ-AUT-13).

func (*Element) Position

func (n *Element) Position() Pos

type ElementAttr added in v0.2.0

type ElementAttr struct {
	Name   string   `json:"name"`
	Kind   string   `json:"kind"`
	Values []string `json:"values,omitempty"`
	Doc    string   `json:"doc,omitempty"`
}

ElementAttr is one attribute of an imported element.

type ElementDef added in v0.2.0

type ElementDef struct {
	Name string `json:"name"`
	Tag  string `json:"tag"`
	Doc  string `json:"doc,omitempty"`
	// Module is the import specifier of the module that defines the
	// element. gx pin holds its file.
	Module     string        `json:"module"`
	Attributes []ElementAttr `json:"attributes"`
	Events     []string      `json:"events"`
	Slots      []string      `json:"slots"`
}

ElementDef is one imported custom element. A tag <pkg.Name> renders the element <Tag>.

type ElementModel added in v0.2.0

type ElementModel struct {
	Name    string `json:"name"`
	Package string `json:"package"`
	Tag     string `json:"tag"`
	// Module is the import specifier of the module that defines the
	// element.
	Module     string        `json:"module"`
	Attributes []ElementAttr `json:"attributes"`
	Events     []string      `json:"events"`
	Slots      []string      `json:"slots"`
}

ElementModel is one imported web component (REQ-ISL-09): the typed tag <package name>.<Name> renders the custom element Tag.

type ElementSet added in v0.2.0

type ElementSet struct {
	// Package and Version name the npm package.
	Package  string       `json:"package"`
	Version  string       `json:"version"`
	Elements []ElementDef `json:"elements"`
}

ElementSet is the content of an ElementsFile.

type Expr

type Expr struct {
	At     Pos
	DataAt Pos
	Data   string
}

Expr is {expr} in text or an attribute value.

func (*Expr) Position

func (n *Expr) Position() Pos

type Field

type Field struct {
	At         Pos
	Doc        string
	Name       string
	Type       string
	Default    string
	HasDefault bool
}

Field is one props or signals field. Doc is the text of the // lines above it, one line per comment line.

type FieldModel

type FieldModel struct {
	Name string `json:"name"`
	Type string `json:"type"`
	// Source is "path", "query", "signal" or "form".
	Source string `json:"source"`
	// Key is the name of the field in its source.
	Key     string `json:"key"`
	Default string `json:"default,omitempty"`
}

FieldModel is one input field of a route.

type File

type File struct {
	File       string
	Package    string
	Imports    []Import
	HasProps   bool
	Props      []Field
	HasSignals bool
	Signals    []Field
	Body       []Node
}

File is the parsed form of one .gx file or fragment.

type FormFieldModel

type FormFieldModel struct {
	Name  string   `json:"name"`
	Type  string   `json:"type"`
	Rules []string `json:"rules"`
}

FormFieldModel is one form field. Name is the form control name; a nested field has a dotted name.

type FormModel

type FormModel struct {
	Handler string           `json:"handler"`
	Route   string           `json:"route"`
	Method  string           `json:"method"`
	Pattern string           `json:"pattern"`
	Fields  []FormFieldModel `json:"fields"`
}

FormModel is one gx.Form with the rules of its input.

type FragmentModel

type FragmentModel struct {
	Name string `json:"name"`
	// Func is the generated function, for example "CartTotal".
	Func string `json:"func"`
	// Params is the parameter list of the generated function.
	Params []ParamModel `json:"params"`
	// Keyed is true when the first parameter is the instance or loop key.
	Keyed bool `json:"keyed"`
}

FragmentModel is one #fragment of a component and its generated function.

type HTMLComment

type HTMLComment struct {
	At   Pos
	Data string
}

HTMLComment is a <!-- ... --> comment. It renders.

func (*HTMLComment) Position

func (n *HTMLComment) Position() Pos

type IconSetModel

type IconSetModel struct {
	Set     string `json:"set"`
	Version string `json:"version"`
}

IconSetModel is one pinned icon set.

type Import

type Import struct {
	Raw string
}

Import is one import spec, as written, without the import keyword.

type Info

type Info struct {
	Code  string
	Title string
}

Info describes one diagnostic code.

type Island added in v0.2.0

type Island struct {
	Name string
	// File is the path of the .ts file.
	File string
	// Props holds the exported fields of the props struct, in source order.
	Props []Prop
	// HasProps is false when the package declares no <Name>Props struct.
	HasProps bool
	// contains filtered or unexported fields
}

Island is one TypeScript island: a .ts file in a Go package that exports a default mount function (REQ-ISL-01). Its props are the Go struct <Name>Props of the same package.

type IslandModel

type IslandModel struct {
	Name    string      `json:"name"`
	Package string      `json:"package"`
	File    string      `json:"file"`
	Props   []PropModel `json:"props"`
}

IslandModel is one TypeScript island (REQ-ISL-01). Props are the exported fields of its Go props struct.

type IslandRef added in v0.2.0

type IslandRef struct {
	// ID is the name the server and the browser use: the import path of the
	// package and the component name.
	ID   string
	Name string
	// File is the path of the .ts file.
	File string
}

IslandRef is one island of a module (REQ-ISL-03).

func Islands added in v0.2.0

func Islands(root string) []IslandRef

Islands returns every island under root, in the order of their IDs. It reads the file names and the default exports only, so the bundler can call it with no type analysis.

type Let

type Let struct {
	At   Pos
	Name string
	Expr string
}

Let is a name := expr statement line.

func (*Let) Position

func (n *Let) Position() Pos

type Model

type Model struct {
	Root        string
	Files       []*File
	Components  []ComponentRef
	Routes      []RouteRef
	Symbols     []Symbol
	Packages    map[string][]string // import path -> exported names
	Collections []CollectionRef     // gx.Collection declarations (REQ-CNT-03)
}

Model is the whole-module index of one analysis pass (REQ-DEV-11). The LSP answers completion, hover and definition from it.

type Module

type Module struct {
	Dir  string
	Path string
}

Module is the enclosing Go module of a package.

type Node

type Node interface {
	Position() Pos
	// contains filtered or unexported methods
}

Node is a markup node.

func VisibleNodes

func VisibleNodes(ns []Node) []Node

VisibleNodes returns the nodes a renderer emits: all nodes except {/* ... */} comments (REQ-AUT-16).

type Package

type Package struct {
	Dir    string
	Module *Module
	Files  map[string]*File // base name without .gx
	// Islands holds the TypeScript islands of the directory by name
	// (REQ-ISL-01).
	Islands map[string]*Island
	// Elements holds the imported web components of the directory by name
	// (REQ-ISL-09).
	Elements map[string]*ElementDef
	Diags    []Diagnostic
}

Package is the parsed .gx files of one directory.

type ParamModel

type ParamModel struct {
	Name string `json:"name"`
	Type string `json:"type"`
}

ParamModel is one parameter of a generated function.

type Pos

type Pos struct {
	Line int
	Col  int
}

Pos is a 1-based position in a .gx file.

type Prop

type Prop struct {
	Name       string
	Doc        string
	Type       string
	Default    string
	HasDefault bool
}

Prop is one component prop, from the props block.

type PropModel

type PropModel struct {
	Name     string `json:"name"`
	Type     string `json:"type"`
	Required bool   `json:"required"`
	Default  string `json:"default,omitempty"`
	Doc      string `json:"doc,omitempty"`
}

PropModel is one prop of a component.

type RegistryModel

type RegistryModel struct {
	Name    string   `json:"name"`
	Version string   `json:"version"`
	Files   []string `json:"files"`
}

RegistryModel is one installed registry item.

type RouteModel

type RouteModel struct {
	// Type is the import path and the type name.
	Type    string       `json:"type"`
	Method  string       `json:"method"`
	Pattern string       `json:"pattern"`
	Fields  []FieldModel `json:"fields"`
	// Kind is "page", "action", "form" or "none" when nothing handles the
	// route.
	Kind string `json:"kind"`
	// Handler is the package-level value that handles the route.
	Handler    string   `json:"handler,omitempty"`
	Prefix     string   `json:"prefix,omitempty"`
	Layouts    []string `json:"layouts,omitempty"`
	Middleware []string `json:"middleware,omitempty"`
}

RouteModel is one route type.

type RouteRef

type RouteRef struct {
	Key        string // import path and type name
	PkgPath    string
	Name       string
	Pattern    string
	Method     string
	File       string
	Line       int
	Col        int
	Fields     []string
	Registered bool
}

RouteRef is one route struct of the module (REQ-DEV-08, REQ-DEV-11).

type RouteReport

type RouteReport struct {
	Type       string   `json:"type"`
	Method     string   `json:"method"`
	Pattern    string   `json:"pattern"`
	Fields     []string `json:"fields"`
	Page       string   `json:"page,omitempty"`
	Prefix     string   `json:"prefix,omitempty"`
	Layouts    []string `json:"layouts,omitempty"`
	Middleware []string `json:"middleware,omitempty"`
}

RouteReport is one entry of `gx routes` (REQ-RTE-14).

type Session

type Session struct {
	// contains filtered or unexported fields
}

Session caches one module analysis across Generate calls, so a change to one .gx body re-checks that file alone and regenerates that file alone (NFR-05, REQ-DEV-03). A change to a Go file, to a .gx signature or to the file set falls back to a full Generate.

func NewSession

func NewSession() *Session

NewSession returns an empty compiler session.

func (*Session) ClearOverlay

func (s *Session) ClearOverlay(path string)

ClearOverlay drops the in-memory content of one file.

func (*Session) Content

func (s *Session) Content(root string) []Diagnostic

Content returns the diagnostics of the Markdown files of every gx.Collection declaration (REQ-CNT-03). An open buffer wins over disk.

func (*Session) Diagnostics

func (s *Session) Diagnostics() []Diagnostic

Diagnostics returns the diagnostics of the last Generate call.

func (*Session) Generate

func (s *Session) Generate(root string) (map[string][]byte, []Diagnostic)

Generate returns the generated files and diagnostics of root, reusing the previous analysis when only .gx bodies changed (NFR-05).

func (*Session) Model

func (s *Session) Model(root string) (*Model, []Diagnostic)

Model runs the analysis and returns the whole-module index. It reuses the session cache, so an edit only re-checks the changed file (REQ-DEV-11).

func (*Session) SetOverlay

func (s *Session) SetOverlay(path string, src []byte)

SetOverlay records in-memory content for one input file. The next Generate call reads the overlay instead of the file on disk.

type SignalModel

type SignalModel struct {
	Name    string `json:"name"`
	Type    string `json:"type"`
	Default string `json:"default"`
	Doc     string `json:"doc,omitempty"`
}

SignalModel is one client signal of a component.

type Symbol

type Symbol struct {
	File       string
	Line       int
	Col        int
	EndCol     int
	Text       string
	Type       string
	ObjectFile string
	ObjectLine int
	ObjectCol  int
}

Symbol is one typed identifier in a .gx file (REQ-DEV-08). ObjectFile is the definition position, mapped through the //line directives.

type Text

type Text struct {
	At   Pos
	Data string
}

Text is literal markup text.

func (*Text) Position

func (n *Text) Position() Pos

type TransitionModel

type TransitionModel struct {
	// Name is the package-level value.
	Name string `json:"name"`
	// Base is the view-transition base name.
	Base string `json:"base"`
	// Key is the key type.
	Key string `json:"key"`
}

TransitionModel is one gx.Transition value.

Jump to

Keyboard shortcuts

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