New releases 4.13 and 5.0

Hello CodeMirror users,

I’ve just tagged releases 4.13 and 5.0. The second includes the new (still experimental) mobile support.

If you want a safe upgrade, use 4.13. It contains the following changes:

  • Fix a bad bug in the closetag addon that would make it impossible to type ‘/’
  • New modes: Forth, Stylus.
  • Make the CSS mode understand some modern CSS extensions.
  • Have the Scala mode handle symbols and triple-quoted strings.

You can see all patches at
And get the zip file at

Version 5.0 adds the possibility to use contentEditable rather than a hidden textarea as a way to manage input and focus. This is necessary on mobile, since it is the only way we can get the native selection interface to show up.

Mobile browsers tested are the iOS browser and Chrome and the stock browser on recent Android versions. Mobile Firefox is still a work in progress.

In this version, there is a new option inputStyle to switch between hidden textarea and contenteditable input. On mobile browsers, the default is "contenteditable". On desktop browsers, the default is "textarea", but if IME or screen reader support is important to you, you might also want to set it to "contenteditable". I very much appreciate people testing this, both on mobile and desktop.

The only incompatible change is that getInputField method is no longer guaranteed to return a textarea.

The new patches in 5.0 are
And the zip is at


Congratulations on the release! and both lead to a 404 for me.

Good point. I forgot to generate the zips. Fixed now.