There are efforts to explore MediaWiki-extensions-CodeMirror as an alternative for CodeEditor across the wikiverse. CodeMirror integration in VisualEditor would be required for this effort to be feature-complete.
There is a ve.ui.MWAceEditorWidget that is used to power syntax highlighting in VisualEditor. This widget is not used directly in VE, but by other extensions integrating with VE:
- MediaWiki-extensions-Graph – via ve.ui.MWGraphDialog
- Maps (Kartographer) – via ve.ui.MWMapsDialog
- Math – via ve.ui.MWLatexDialog
- MediaWiki-extensions-Score – via ve.ui.MWScoreDialog
- SyntaxHighlight – via ve.ui.MWSyntaxHighlightDialog
- StarCitizenTools/mediawiki-extensions-TabberNeue – via ve.ui.MWTabberDialog
Presumably, in order to have CodeMirror be a suitable drop-in replacement, we'd need to add more language modes, such as those that Extension:SyntaxHighlight supports.
Additionally, we'll need configuration flags to control the use of CodeMirror over CodeEditor. Other extensions are doing this with a pair of flags, which in this case would be $wgVisualEditorUseCodeEditor and $wgVisualEditorUseCodeMirror.