Provides methods to access the components schema

Internal

Other

  • Gets default data for a component

    Parameters

    • component: string

      The component name

    Returns object

    The default data

    Example

    const modelData = editor.schema.components.getDefaultData('model');
    
  • Gets a list of fields of a particular type for a component

    Parameters

    • componentName: string

      The component name

    • type: string

      The desired type

    Returns string[]

    A list of fields

    Example

    const buttonEntityFields = editor.schema.components.getFieldsOfType('button', 'entity');