formatter
Internal library of helpers for formatting GraphQL values.
getFormattedDefaultValue()β
function getFormattedDefaultValue<T>(entity): Maybe<string | T>
Returns a printable formatted value for a GraphQL type. This is the generic function.
Type Parametersβ
β’ T
Parametersβ
β’ entity
the GraphQL schema entity processed.
β’ entity.defaultValue: T
the GraphQL schema type's value to be formatted.
β’ entity.type: Maybe
<GraphQLType
>
the GraphQL schema type.
Returnsβ
Maybe
<string
| T
>
a printable formatted value.
Defined inβ
packages/graphql/src/formatter.ts:94