Skip to content

Commit 1a8099a

Browse files
committed
feature/Add line wrapping to codemirror
1 parent 4e5ddb9 commit 1a8099a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

app/javascript/controllers/codemirror_controller.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ export default class extends Controller {
2929
this.codeMirror = CodeMirror.fromTextArea(this.mirrorTarget, {
3030
theme: 'one-light',
3131
mode: "javascript",
32-
readOnly: this.readOnlyValue ? 'nocursor' : false
32+
readOnly: this.readOnlyValue ? 'nocursor' : false,
33+
lineWrapping: true
3334
});
3435

3536
this.initializedValue = true

0 commit comments

Comments
 (0)