generator

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: May 31, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FetchModuleTemplate

func FetchModuleTemplate() *template.Template

FetchModuleTemplate returns the go template for fetch module.

func JSONCamelCase

func JSONCamelCase(s string) string

JSONCamelCase converts a snake_case identifier to a camelCase identifier, according to the protobuf JSON specification.

Copied from: google.golang.org/protobuf/internal/strs.

func ServiceTemplate

func ServiceTemplate(r *registry.Registry) *template.Template

ServiceTemplate gets the template for the primary typescript file.

Types

type TemplateData

type TemplateData struct {
	*data.File
	EnableStylingCheck bool
	UseStaticClasses   bool
}

Data object injected into the templates.

type TypeScriptGRPCGatewayGenerator

type TypeScriptGRPCGatewayGenerator struct {
	Registry *registry.Registry
}

TypeScriptGRPCGatewayGenerator is the protobuf generator for typescript.

func New

New returns an initialised generator.

func (*TypeScriptGRPCGatewayGenerator) Generate

Generate take a code generator request and returns a response. it analyse request with registry and use the generated data to render ts files.

Jump to

Keyboard shortcuts

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