1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-26 22:41:17 +02:00

Desktop: Resolves #4727: Add support for safe mode, which temporarily disables note rendering and plugins

This commit is contained in:
Laurent Cozic
2021-04-24 20:23:33 +02:00
parent 920f54f5d3
commit 3235f58f5a
13 changed files with 111 additions and 15 deletions

View File

@@ -7,6 +7,7 @@ import htmlUtils from './htmlUtils';
import Resource from './models/Resource';
export class MarkupLanguageUtils {
private lib_(language: MarkupLanguage) {
if (language === MarkupLanguage.Html) return htmlUtils;
if (language === MarkupLanguage.Markdown) return markdownUtils;
@@ -31,6 +32,7 @@ export class MarkupLanguageUtils {
pluginOptions: pluginOptions,
tempDir: Setting.value('tempDir'),
fsDriver: shim.fsDriver(),
isSafeMode: Setting.value('isSafeMode'),
}, options);
return new MarkupToHtml(options);