How to autocomplete groovy methods using monaco editor

1k Views Asked by At

I use monaco editor with groovy language. How to autocomplete methods by type ? e.g., defining a String var1 = "abc", when user types vars. , how to suggest the String related methods, such as .toString, .charArray, .length etc...

1

There are 1 best solutions below

0
On

You can use the Language Server Protocol, as described here for python:
https://stackoverflow.com/a/71349842/10985072
For Groovy, you can search this list of language servers for Groovy language servers.