Merge pull request #2922 from uxen-ab/issue-2749-template-editing

Fixes the template editing as it was done in pull #2866 for creation.
This commit is contained in:
James Brooks
2018-03-06 08:25:35 +00:00
committed by GitHub

View File

@@ -9,13 +9,14 @@
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.8.0/mode/twig/twig.min.js"></script>
<script>
(function() {
var editor = CodeMirror.fromTextArea(document.getElementById('cm-editor'), {
lineNumbers: true,
mode: 'twig',
lineWrapping: true
});
}());
//Initializes the editor only once the DOM is loaded.
window.addEventListener("DOMContentLoaded", function(e) {
var editor = CodeMirror.fromTextArea(document.getElementById('cm-editor'), {
lineNumbers: true,
mode: 'twig',
lineWrapping: true
});
});
</script>
@stop