-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(typescript) $class variable is incorrectly highlighted as a keyword #2516
Comments
This is a limitation of how we process keywords because technically the tiny area between To fix it we'd have to hardcode a rule to match all
What method? Also see my comment on isBool.
We don't have a completely list of types in our grammar... if you have a suggestion of which ones we should add we could discuss it and see if we can find an agreement - but I'm not sure we should "add them all" because there are a ton of them. For example TypeScript's DOM type definition has 100s of types: https://github.com/Microsoft/TypeScript/blob/master/lib/lib.dom.d.ts So we'd need some way to decide on the "major" ones...
It wouldn't be, we don't highlight method invocation. |
@egor-rogov Actually I wonder if we just extended See any downsides? |
Yeah, I agree. |
Yes, in JS/TS $ and _ are just characters like any other. Hence jQuery $ and _ (underscore) libs. |
I don't see any downsides to this since |
Fix will go out in 10.1. |
Describe the issue
Which language seems to have the issue?
Are you using
highlight
orhighlightAuto
?highlight
...
Sample Code to Reproduce
https://jsfiddle.net/fsLxdrpm/1/
Expected behavior
$class
prefix with$
went wrongclass
name went wrongThe text was updated successfully, but these errors were encountered: