mathieudutour / mathieudutour/vscode-firebase

Erroneous highlighting of "match"

Open
#1 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
16
Forks
0
PR merge metrics
No merged PRs in 30d

Description

Hi,

Great work with this project!

I noticed that if I use a function named "matchXyz", the word 'match' is highlighted as if it was a keyword.

Please see how this example is highlighted:
```css
service cloud.firestore {
function matchName(name) {
return name === "john";
}

match /databases/{database}/documents {
match /users/{username} {
allow update: if matchName(username);
}
}
}
```
It looks like this with the extension installed:
image

The "match" on ln 8 should not be highlighted.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the reported highlighting in the VSCode Firebase extension with the Firestore Security Rules example from the issue. Find the syntax-highlighting entry point for Firestore rules and verify that matchName is not treated as the match keyword, while standalone match expressions remain highlighted. No file or test is named in the report.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.