Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var GraphFilter = loadLocalTpl("templates/graphers_filter.tmpl")
View Source
var GraphQuery = loadLocalTpl("templates/graphers_query.tmpl")
View Source
var GraphTypes = loadLocalTpl("templates/graphers_types.tmpl")
View Source
var (
TemplateFuncs = template.FuncMap{
"HasType": hasType,
"GqlType": gqlType,
"GqlTypeString": gqlTypeString,
"IsOutput": ouputField,
"IsCreate": createField,
"IsUpdate": updateField,
"IsInterface": isInterface,
}
)
Functions ¶
func NewExtension ¶
Types ¶
type Annotation ¶
type Annotation struct { Type graphql.Type SkipOutput bool SkipCreate bool SkipUpdate bool IsInterface bool }
Annotation annotates fields and edges with metadata for templates.
func IsInterface ¶
func IsInterface() Annotation
func SkipAll ¶
func SkipAll() Annotation
func SkipCreate ¶
func SkipCreate() Annotation
func SkipOutput ¶
func SkipOutput() Annotation
func SkipUpdate ¶
func SkipUpdate() Annotation
func Type ¶
func Type(t graphql.Type) Annotation
func (Annotation) Name ¶
func (Annotation) Name() string
type EntGraphers ¶
type EntGraphers struct {
entc.DefaultExtension
}
func (EntGraphers) Annotations ¶
func (EntGraphers) Annotations() []schema.Annotation
func (EntGraphers) Templates ¶
func (EntGraphers) Templates() []*gen.Template
Click to show internal directories.
Click to hide internal directories.