Interface: AsEnumTypeMetadata<TInput>

GraphQL enum type metadata type.

Extends

  • BaseMetadata<TInput>

Type Parameters

TInput extends string | number

Properties

~types?

readonly optional ~types: object

Internal

The input, output and issue type.

input

readonly input: TInput

issue

readonly issue: never

output

readonly output: TInput

Inherited from

BaseMetadata.~types

Defined in

node_modules/.pnpm/valibot@1.0.0-beta.7_typescript@5.4.3/node_modules/valibot/dist/index.d.ts:2962


config

readonly config: EnumTypeConfig<TInput>

The GraphQL enum type config.

Defined in

packages/valibot/src/metadata.ts:290


kind

readonly kind: "metadata"

The object kind.

Inherited from

BaseMetadata.kind

Defined in

node_modules/.pnpm/valibot@1.0.0-beta.7_typescript@5.4.3/node_modules/valibot/dist/index.d.ts:2948


reference()

readonly reference: <TInput>(name) => AsEnumTypeMetadata<TInput><TInput>(config) => AsEnumTypeMetadata<TInput>

The metadata reference.

Creates a GraphQL enum type metadata.

Type Parameters

TInput extends string | number

Parameters

name: string

The GraphQL enum name.

Returns

AsEnumTypeMetadata<TInput>

A GraphQL enum type metadata.

Creates a GraphQL enum type metadata.

Type Parameters

TInput extends string | number

Parameters

config: EnumTypeConfig<TInput>

The GraphQL enum config.

Returns

AsEnumTypeMetadata<TInput>

A GraphQL enum type metadata.

Overrides

BaseMetadata.reference

Defined in

packages/valibot/src/metadata.ts:285


type

readonly type: "gqloom.asEnumType"

The metadata type.

Overrides

BaseMetadata.type

Defined in

packages/valibot/src/metadata.ts:281