eclipse-langium / langium

Next-gen language engineering / DSL framework
https://langium.org/
MIT License
725 stars 65 forks source link

Add service for text document handling #1272

Closed msujew closed 4 months ago

msujew commented 11 months ago

Currently, the language-server.ts has a function to register a text document handler. This function is hardly overridable, and doesn't allow to query whether certain operations are supported (such as onWillSave).

It would be a good idea to extract this handler method into an interface + default implementation that can be used to provide better server capability info and more fine grained text document handling.

msujew commented 9 months ago

Reopening this, as events such as onDidSave and onWillSave are still not covered by the language server by default.