From 9716e6072007d5a17f73e924ca2722d21095f172 Mon Sep 17 00:00:00 2001 From: mkslanc Date: Sun, 13 Nov 2022 16:35:46 +0400 Subject: [PATCH] change curly braces insertion behavior for Markdown to act the same as for other braces --- src/mode/markdown.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/mode/markdown.js b/src/mode/markdown.js index f2a067ebb72..3aab4155074 100644 --- a/src/mode/markdown.js +++ b/src/mode/markdown.js @@ -1,10 +1,8 @@ "use strict"; var oop = require("../lib/oop"); +var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour; var TextMode = require("./text").Mode; -var JavaScriptMode = require("./javascript").Mode; -var XmlMode = require("./xml").Mode; -var HtmlMode = require("./html").Mode; var MarkdownHighlightRules = require("./markdown_highlight_rules").MarkdownHighlightRules; var MarkdownFoldMode = require("./folding/markdown").FoldMode; @@ -21,7 +19,7 @@ var Mode = function() { }); this.foldingRules = new MarkdownFoldMode(); - this.$behaviour = this.$defaultBehaviour; + this.$behaviour = new CstyleBehaviour({ braces: true }); }; oop.inherits(Mode, TextMode);