cx-composer--for=liferay

Editor Config Contributor

Extend the configuration of Liferay's rich-text editors.

type: editorConfigContributor·Frontend·Liferay docs →

# description

Adds JavaScript that mutates the CKEditor / AlloyEditor configuration object before the editor initializes.

UI extensions that render on Liferay pages or modify page appearance.

# when to use

  • You need custom toolbar buttons, plugins, or content filters in editors.
  • You want editor configs to differ per portlet (only comments, only web-content, etc.).

# how to use

  1. 01Export a default function that receives + returns a config object.
  2. 02Optionally scope the override via editorConfigKeys, editorNames, or portletNames.

# required fields

fieldtypedescription
urlrequiredstringPath to the JS module implementing the contributor.

# optional fields

fieldtypedescription
namestringDisplay name.
editorConfigKeysstring[]Editor configuration keys this contributor overrides; omit = all.
editorNamesstring[]Restrict to specific editors.
portletNamesstring[]Restrict to editors inside specific portlets.

# example

client-extension.yaml
my-editor-config:
    type: editorConfigContributor
    name: Custom Toolbar
    url: editor-config.js
    portletNames:
        - com_liferay_journal_web_portlet_JournalPortlet

# more in frontend