components

package
v0.0.2-0...-87e7576 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2019 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var EOT = es.New("end of tag")

Functions

func ProcessAll

func ProcessAll(base string)

ProcessAll processes components starting at base

Types

type Component

type Component struct {
	Name     string
	Template string
	Style    string
	Package  string
	Imports  []string

	Struct   bool
	UniqueID string
	// contains filtered or unexported fields
}

A Component represents a web component in an HTML file

func Parse

func Parse(r io.Reader, name string) *Component

Parse reads a component file like Nav.html into a Component structure

func (*Component) QuotedStyle

func (c *Component) QuotedStyle() string

func (*Component) QuotedTemplate

func (c *Component) QuotedTemplate() string

func (*Component) Transform

func (c *Component) Transform(w io.Writer)

func (*Component) TransformStyle

func (c *Component) TransformStyle()

func (*Component) WriteImports

func (c *Component) WriteImports() string

type Transpiler

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

func NewTranspiler

func NewTranspiler(r io.ReadCloser, createStruct bool, appPackage, componentName, packageName string) *Transpiler

func (*Transpiler) Code

func (s *Transpiler) Code() string

Jump to

Keyboard shortcuts

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