enum

package
v0.0.27 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEnums

func GetEnums(tsName, gqlName, gqlType string, values []string) (*Enum, *GQLEnum)

func GetTSEnumNameForVal

func GetTSEnumNameForVal(val string) string

Types

type Data

type Data struct {
	Name        string
	Value       string
	Comment     string
	PackagePath string
}

type Enum

type Enum struct {
	Name     string
	Values   []Data
	Imported bool // Imported enum that's not in this file
}

type GQLEnum

type GQLEnum struct {
	Name   string // Name is the name of the enum
	Type   string // type of the enum e.g. nullable or not
	Values []Data
}

Jump to

Keyboard shortcuts

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