Codemirror’s css classes are pretty limited, and in many cases ambiguous. This causes a lot of cross-mode theme inconsistencies and often prevents smarter highlighting. I’d like to add more detailed classes to some tokens. For example a javascript tokenizer can easily distinguish that all blah
in the following are function names, distinct from variables.
function blah() {}
blah()
blah.apply()
blah.call()
```
What would be the best way to add extra classes, like `.cm-function` to these tokens? Are there external hooks for the tokenizer or parser? Do I need to create an overlay mode? A wrapping mode?
Thanks!