About Data

Alpha: Editor React Components are currently in alpha. This feature is subject to change and may have bugs, issues, and limitations. We're actively improving it based on your feedback.

The data property of your manifest controls how Wix users configure component properties and what data your component receives at runtime. When building custom components, you often want Wix users to configure specific properties like text, images, links, colors, or dates. Based on your data type definitions, the editor automatically generates the appropriate UI controls in panels in the editor. For example, if you define a date picker type, a date picker control appears when Wix users open the settings panel.

The displayName you provide becomes the label Wix users see in the editor panel.

Where to define

You can define data in:

The data property is optional.

Data item fields

Each property in your data object is a data item. A data item is an object with core fields that every data type shares, plus type-specific fields for additional configuration.

Core fields

dataTypeDataTypeRequired

The type of data this item stores. Determines validation, UI controls, and runtime format.


displayNamestring

Label shown in the editor. If omitted, the property key is used.


defaultValueValue

Initial value when the component is first added. This is what initially appears in the settings panel for this item. Format must match the runtime prop format.

Type-specific fields

Some data types require or allow additional configuration beyond the core fields. When a type supports extra configuration, those options go in a field named after the type itself.

For example, a text data type can have a text field with validation options:

Copy

For details on each type and its configuration options, see the type reference pages in Available data types.

Available data types

When you define data items in your manifest, you choose from a set of predefined data types. Each type comes with built-in validation, UI controls in the editor, and a corresponding runtime format. TypeScript types for all props are available from the @wix/editor-react-types package.

Available data types organized by category:

CategoryData TypeType-Specific FieldsDescription
Primitive TypestextA simple text value.
numberNumeric values with optional validation constraints.
booleanValuetrue or false.
guidGlobally unique identifier.
Text VariationstextEnumA list of predefined textual values to choose from.
richTextHTML text with inline CSS styling.
regexValid regex pattern.
directionText direction.
Date and TimelocalDateLocal date in ISO-8601 format YYYY-MM-DD.
localTimeLocal time in ISO-8601 format hh:mm[:ss][.sss].
localDateTimeLocal date-time in ISO-8601 format YYYY-MM-DDThh:mm[:ss][.sss].
Contact InformationemailStandard email address RFC 5321.
phonePhone number with common formatting characters.
webUrlURL with http or https scheme.
hostnameIANA hostname.
MediaimageWix Image object.
videoWix Video object.
vectorArtWix Sanitized Vector Art (SVG).
audioWix Audio object.
LinklinkWix Link object.
ContainercontainerContainer for child components.
Complex TypesdataComplex nested data structure.
arrayItemsArray of data items.
menuItemsSite navigation menu items.
Accessibilitya11yAccessibility fields.
Event HandlersonClickClick event handler.
onChangeInput change event handler.
onKeyPressKey press event handler.
onKeyUpKey up event handler.
onKeyDownKey down event handler.
onFocusFocus event handler.
onSubmitForm submit event handler.
functionCustom function handler.
Did this help?