The App: I have a textarea element in my page. It is transformed using CodeMirror, because I need to indent and highlight html code withing it. Pic is in the li
This works work CodeMirror 5.22.0:
CodeMirror.fromTextArea(document.getElementById('grammar'), { lineNumbers: true, mode: 'pegjs', }).on('change', editor => { console.log(editor.getValue()); });