CustomFields

CustomFields

Most entities can have additional fields added to them by defining an array of CustomFieldConfig objects on against the corresponding key.

Example

bootstrap({
    // ...
    customFields: {
        Product: [
            { name: 'infoUrl', type: 'string' },
            { name: 'downloadable', type: 'boolean' },
            { name: 'shortName', type: 'localeString' },
        ],
        User: [
            { name: 'socialLoginToken', type: 'string' },
        ],
    },
})

Signature

interface CustomFields {
  Address?: CustomFieldConfig[];
  Collection?: CustomFieldConfig[];
  Customer?: CustomFieldConfig[];
  Facet?: CustomFieldConfig[];
  FacetValue?: CustomFieldConfig[];
  GlobalSettings?: CustomFieldConfig[];
  Product?: CustomFieldConfig[];
  ProductOption?: CustomFieldConfig[];
  ProductOptionGroup?: CustomFieldConfig[];
  ProductVariant?: CustomFieldConfig[];
  User?: CustomFieldConfig[];
}

Members

Address

property

Collection

property

Customer

property

Facet

property

FacetValue

property

GlobalSettings

property

Product

property

ProductOption

property

ProductOptionGroup

property

ProductVariant

property

User

property

Contents:

alpha