web

package
v0.2.8 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Generate

func Generate(state *State) ([]byte, error)

Generate the web server from state

Types

type Generator

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

func New

func New(module *gomod.Module, parser *parser.Parser) *Generator

func (*Generator) GenerateFile

func (g *Generator) GenerateFile(fsys genfs.FS, file *genfs.File) error

type Resource added in v0.2.6

type Resource struct {
	Import *imports.Import
	Camel  string
}

Resource is a web package that will register its routes

type State

type State struct {
	Imports   []*imports.Import
	Resources []*Resource
}

func Load

func Load(fsys fs.FS, module *gomod.Module, parser *parser.Parser) (*State, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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