mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 17:59:23 -04:00
[Monaco] Add JSON syntax support to the Monaco editor (#143739)
* Add JSON syntax support to the Monaco editor * Bump `monaco-editor` version * Fix the `monaco` package and usages to initialize lazily * Add a story demonstrating JSON schema usage
This commit is contained in:
parent
f5acf76351
commit
9456303c97
12 changed files with 151 additions and 88 deletions
|
@ -62,5 +62,7 @@ export const lexerRules = {
|
|||
},
|
||||
} as monaco.languages.IMonarchLanguage;
|
||||
|
||||
monaco.languages.setMonarchTokensProvider(LANGUAGE_ID, lexerRules);
|
||||
monaco.languages.setLanguageConfiguration(LANGUAGE_ID, languageConfiguration);
|
||||
monaco.languages.onLanguage(LANGUAGE_ID, () => {
|
||||
monaco.languages.setMonarchTokensProvider(LANGUAGE_ID, lexerRules);
|
||||
monaco.languages.setLanguageConfiguration(LANGUAGE_ID, languageConfiguration);
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue