Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve "word" experience in vscode. (#225)
The model (form language-configuration.json) accepts '-' as long as it is surrounded by '\w'. However, the editor still uses '-' as word boundary. This combination sounds counter-intuitive, but works okish with highlighting: the model is used to find the initial word, and the editor then finds "whole" words by using the separators. This means that `--foo-bar` finds other `foo-bar`s (and, more importantly, `foo-bar` also finds `--foo-bar`). However, it also means that `foo-bar-gee` will now also be highlighted for the `foo-bar` part. A correct solution will use the LSP, which can provide a good list of the identifiers that are relevant. (Initially maybe just all identifiers that would match).
- Loading branch information