add TypeScript keywords + future reserved keywords #11
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "add-keywords"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
add the following keywords:
enumimplementsinterfacepackageprivateprotectedpublictype@marijnh I think that ideally some should be TypeScript only, also some should be scoped to the strict mode per the spec, but that would require greater changes. In the meantime I think that these should be added sooner rather than later as currently they can't be styled.
What does that mean? If you turn on TypeScript, these should all be highlighted correctly. Adding them as completions does not affect whether they are styled or not.
Attached patch adds this in a way where it only takes effect when TypeScript is actually enabled, and using snippets where appropriate.
I'm defining my own syntax highlighting styles with
syntaxHighlighting(HighlightStyle.define(TagStyle[])), then using tags as{tag: tags.keyword, color: 'var(--code-keyword)'}.I meant that before this change these keywords were being identified as something else, then we had to style them as something else, not keywords as they are.
Thanks!
Right. But that's not accurate (that array you changed has no effect at all on the parse tree or highlighting).
Pull request closed