In IBM WebSphere Portal v8.5 a new extension point was exposed within the Web Content Manager (WCM) Authoring portlet to support replacing all HTML fields with a custom editor.

The extension works in the same way as all other custom fields of WCM. The extension is documented with a sample here: http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/wcm/wcm_dev_custom_html_editor.dita?lang=en

CodeMirror is described on their web site as “a versatile text editor implemented in JavaScript for the browser. It is specialized for editing code, and comes with a number of language modes and addons that implement more advanced editing functionality.”

This sample includes all the files necessary to integrate CodeMirror (http://codemirror.net/) into WCM and to deploy it onto your portal server.