Skip to content

Commit

Permalink
variable to turn on/off highlighter
Browse files Browse the repository at this point in the history
  • Loading branch information
omedtjeee committed Apr 30, 2021
1 parent e4a72f5 commit a499eb4
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions static/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
var editor = window.editor = ace.edit("editor");
editor.setTheme("ace/theme/monokai");

// a variable which turns on(1) highlighter or turns it off(0)
var highlighter = 0;

if (highlighter == 1){
if (window.State.level == 1){
window.editor.session.setMode("ace/mode/level1");
}
Expand All @@ -18,6 +22,7 @@
if (window.State.level == 3){
window.editor.session.setMode("ace/mode/level3");
}
}



Expand Down

0 comments on commit a499eb4

Please sign in to comment.