Skip to content

Commit fbb9afe

Browse files
feat(prettierOnMarkdown):Fixed incorrect options passed to code mirror instance
1 parent 020bc11 commit fbb9afe

File tree

1 file changed

+3
-2
lines changed
  • browser/main/modals/PreferencesModal

1 file changed

+3
-2
lines changed

browser/main/modals/PreferencesModal/UiTab.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class UiTab extends React.Component {
3131
CodeMirror.autoLoadMode(this.codeMirrorInstance.getCodeMirror(), 'javascript')
3232
CodeMirror.autoLoadMode(this.customCSSCM.getCodeMirror(), 'css')
3333
CodeMirror.autoLoadMode(this.customMarkdownLintConfigCM.getCodeMirror(), 'javascript')
34-
CodeMirror.autoLoadMode(this.prettierConfigCM.getCodeMirror(), 'json')
34+
CodeMirror.autoLoadMode(this.prettierConfigCM.getCodeMirror(), 'javascript')
3535
// Set CM editor Sizes
3636
this.customCSSCM.getCodeMirror().setSize('400px', '400px')
3737
this.prettierConfigCM.getCodeMirror().setSize('400px', '400px')
@@ -912,7 +912,8 @@ class UiTab extends React.Component {
912912
value={config.editor.prettierConfig}
913913
options={{
914914
lineNumbers: true,
915-
mode: 'json',
915+
mode: 'application/json',
916+
lint: true,
916917
theme: codemirrorTheme
917918
}} />
918919
</div>

0 commit comments

Comments
 (0)