From 350254af2b7689a40733c999b3b75b250c752fcd Mon Sep 17 00:00:00 2001 From: Pelanyo Kamara Date: Tue, 14 Dec 2021 17:12:26 +0000 Subject: [PATCH] remove annoying soft-tab behaviour and add dedent --- docs/_includes/repl.html | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/_includes/repl.html b/docs/_includes/repl.html index 7330dfaf..bb74abec 100644 --- a/docs/_includes/repl.html +++ b/docs/_includes/repl.html @@ -39,8 +39,16 @@ matchBrackets: true, lineNumbers: true, smartIndent: true, + indentWithTabs: true, + indentUnit: 4, }); editor.setValue("print(\"Hello World!\")\n"); + editor.addKeyMap({ + "Shift-Tab": function (cm) { + // dedent functionality + cm.execCommand("indentLess"); + } + }); // Misc Functions function output(text) {