microsoft / microsoft/TypeScript-Sublime-Plugin
Decorators are not correctly highlighted
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.7k
- Forks
- 236
- Avg merge
- 21d 13h
- Merged PRs (30d)
- 1
Description
When using a decorator in typescript the decorator should be highlighted as a function, since it is an implicit function call.
Currently, @foo and @foo() are not highlighted the same, but since both are clearly decorator calls they should be; in particular @foo is currently not highlighted any particular color.
I tried to figure out how to add this myself but haven't been successful so far -- I'm just not familiar with how tmLanguage files work :-/ If you want to give me tips to get started I'm willing to try to do this myself
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the TypeScript tmLanguage grammar files and reading the decorator rules that handle @foo and @foo(). Compare the scopes assigned to both forms and verify that each receives the same function highlighting when the grammar is updated.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100