Use json from legacy-modes It seems that json is better highlighted under the legacy modes then the modern lang-json package. We'll switch to legacy-modes for json for now until it is fixed. Change-Id: I53859c6d0343059470012e5dd836e3530aa0fbb0
diff --git a/web/element/language.ts b/web/element/language.ts index d26b034..ba76215 100644 --- a/web/element/language.ts +++ b/web/element/language.ts
@@ -46,6 +46,7 @@ import {http} from '@codemirror/legacy-modes/mode/http'; import {idl} from '@codemirror/legacy-modes/mode/idl'; import {jinja2} from '@codemirror/legacy-modes/mode/jinja2'; +import {json} from '@codemirror/legacy-modes/mode/javascript'; import {jsonld} from '@codemirror/legacy-modes/mode/javascript'; import {julia} from '@codemirror/legacy-modes/mode/julia'; import {kotlin} from '@codemirror/legacy-modes/mode/clike'; @@ -110,7 +111,6 @@ import {html} from '@codemirror/lang-html'; import {java} from '@codemirror/lang-java'; import {javascript} from '@codemirror/lang-javascript'; -import {json} from '@codemirror/lang-json'; import {less} from '@codemirror/lang-less'; import {markdown} from '@codemirror/lang-markdown'; import {php} from '@codemirror/lang-php'; @@ -161,7 +161,7 @@ case 'text/x-cmake': return StreamLanguage.define(cmake); case 'application/json': - return json(); + return StreamLanguage.define(json); case 'text/x-cobol': return StreamLanguage.define(cobol); case 'text/x-coffeescript':