Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface TypeConfig

Hierarchy

  • TypeConfig

Index

Properties

Optional computeArgumentsForField

computeArgumentsForField: undefined | ((fieldName: string, args: ReadonlyArray<IntrospectionInputValue>) => Record<string, any> | null)

Allows you to dynamically provide arguments for a given field

Optional excludeFields

excludeFields: string[] | ((fieldName: string, fetchType: FetchQueryType) => boolean)

Allows you to exclude certain fields, either by passing an array (e.g. ['field1', 'field2']) or a function

By default all Scalars, Enums and List<Scalar|Enum>. are queried. If you have expansive computations that you don't want to expose to react-admin, this is the perfect place to do so :).

Optional expand

expand: undefined | false | true

Will expand this type, by default only Scalars, Enums and List<Scalar|Enum>. are expanded. Make sure you expand subtypes as well if required.

Optional includeFields

includeFields: string[] | ((fieldName: string, fetchType: FetchQueryType) => boolean)

Same as exclude fields, but if provided will let you dynamically decide if a field is queried. Will only pass fields of type Scalar, Enum and List<Scalar|Enum>. You can only provide either includeFields or excludeFields.

Optional pluralize

pluralize: undefined | ((name: string) => string)

Optional choose your own plural form

Optional queryValueToInputValue

queryValueToInputValue: undefined | ((value: any) => any)

Allows you to map the value if used as an input type for mutations

Some values might not convert 1:1 if returned from the query and used as an input

Generated using TypeDoc