Skip to content

@vttforge/core / ForeignDocumentFieldOptions

Interface: ForeignDocumentFieldOptions

Properties shared by every Foundry data field option object.

Mirrors the base DataFieldOptions interface documented at https://foundryvtt.com/api/classes/foundry.data.fields.DataField.html.

Extends

Properties

gmOnly?

readonly optional gmOnly?: boolean

Inherited from

DataFieldOptions.gmOnly


hint?

readonly optional hint?: string

Inherited from

DataFieldOptions.hint


idOnly?

readonly optional idOnly?: boolean

Keep the stored id instead of resolving the document.

With this off, the field initializes to a getter: reading the property gives you a function, and calling it looks the document up. That is why the two cases infer to different types.


initial?

readonly optional initial?: unknown

Inherited from

DataFieldOptions.initial


label?

readonly optional label?: string

Inherited from

DataFieldOptions.label


nullable?

readonly optional nullable?: boolean

Inherited from

DataFieldOptions.nullable


readonly?

readonly optional readonly?: boolean

Inherited from

DataFieldOptions.readonly


required?

readonly optional required?: boolean

Inherited from

DataFieldOptions.required


validate?

readonly optional validate?: (value) => boolean | undefined

Parameters

value

unknown

Returns

boolean | undefined

Inherited from

DataFieldOptions.validate


validationError?

readonly optional validationError?: string

Inherited from

DataFieldOptions.validationError

MIT licensed.