Skip to main content

formatter

Internal library of helpers for formatting GraphQL values.

getFormattedDefaultValue()

function getFormattedDefaultValue<T>(entity): Maybe<string | T>

Defined in: packages/graphql/src/formatter.ts:94

Returns a printable formatted value for a GraphQL type. This is the generic function.

Type Parameters

T

Parameters

entity

the GraphQL schema entity processed.

defaultValue

T

the GraphQL schema type's value to be formatted.

type

Maybe<GraphQLType>

the GraphQL schema type.

Returns

Maybe<string | T>

a printable formatted value.