From 2ae804c0f470e74dabf5d31bd23575ccc47e2073 Mon Sep 17 00:00:00 2001 From: Mo Bitar Date: Thu, 11 Apr 2019 10:28:17 -0500 Subject: [PATCH] Disable spellcheck by default on desktop --- app/assets/javascripts/app/controllers/editor.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/app/controllers/editor.js b/app/assets/javascripts/app/controllers/editor.js index bb1403e37..4790a42ae 100644 --- a/app/assets/javascripts/app/controllers/editor.js +++ b/app/assets/javascripts/app/controllers/editor.js @@ -548,7 +548,11 @@ angular.module('app') this.loadPreferences = function() { this.monospaceFont = authManager.getUserPrefValue("monospaceFont", "monospace"); - this.spellcheck = authManager.getUserPrefValue("spellcheck", true); + + // On desktop application, disable spellcheck by default, as it is not performant. + let defaultSpellcheckStatus = isDesktopApplication() ? false : true; + this.spellcheck = authManager.getUserPrefValue("spellcheck", defaultSpellcheckStatus); + this.marginResizersEnabled = authManager.getUserPrefValue("marginResizersEnabled", true); if(!document.getElementById("editor-content")) {