3 ms·
Is there some documentation of how to integrate some kind of intellisense for a custom language to it and not only syntax highlighting? I might need to integra
by Matthias247 10y ago
Is there some documentation of how to integrate some kind of intellisense for a custom language to it and not only syntax highlighting?
I might need to integrate an editor for a custom DSL into a webapp soon, and Monaco could of course be an interesting alternative to codemirror or ACE.
- alexdima 10y agoHere [1] is a working sample showing how to register a completion item provider for a language. The monaco-typescript [2] plugin shows how a lot of the language API can be used. [1] https://microsoft.github.io/monaco-editor/playground.html#extending-language-services-custom-languages https://microsoft.github.io/monaco-editor/playground.html#ex... [2] https://github.com/Microsoft/monaco-typescript/blob/master/src/mode.ts#L44 https://github.com/Microsoft/monaco-typescript/blob/master/s...
- Matthias247 10y agoThanks, that should be a good start. [1] does not demonstrate context-dependent completions, but I guess it should be possible, and maybe [2] helps there. It's also nice that in the playground intellisense for the monaco API is enabled.