Skip to content

Commit

Permalink
docs/faq.md: update the vscode default text mate rule project
Browse files Browse the repository at this point in the history
VS Code changed its TextMate rule source to worlpaker/go-syntax.

Change-Id: I5c59ac851731c388a2a8a317ed5a3c5ca0946a69
Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/582675
Reviewed-by: Peter Weinberger <pjw@google.com>
Commit-Queue: Hyang-Ah Hana Kim <hyangah@gmail.com>
kokoro-CI: kokoro <noreply+kokoro@google.com>
  • Loading branch information
hyangah committed May 1, 2024
1 parent ff0beea commit fe57357
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ extension.
<br/><em>(Toggle Test File)</em></p>

**⚠️ Note**: the default syntax highlighting for Go files is provided by a
[TextMate rule](https://github.com/jeff-hykin/better-go-syntax) embedded in VS
[TextMate rule](https://github.com/worlpaker/go-syntax) embedded in VS
Code, not by this extension.

For better syntax highlighting, we recommend enabling
Expand Down
9 changes: 7 additions & 2 deletions docs/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,22 @@
## Syntax highlighting doesn't seem to work.

The default syntax highlighting for Go files is provided by a
[TextMate rule](https://github.com/jeff-hykin/better-go-syntax) embedded in VS Code,
[TextMate rule](https://github.com/worlpaker/go-syntax) embedded in VS Code,
not by this extension.

For better syntax highlighting (including generics support), we recommend enabling
For accurate syntax highlighting (including generics support), we recommend enabling
[semantic highlighting](https://code.visualstudio.com/api/language-extensions/semantic-highlight-guide)
by turning on [Gopls' `ui.semanticTokens` setting](settings.md#uisemantictokens).

```json
"gopls": { "ui.semanticTokens": true }
```

If you are experiencing issues with syntax highlighting, first check if you
are using semantic highlighting. In case you did not enable semantic highlighting,
report the issues to the [go-syntax](https://github.com/worlpaker/go-syntax)
project directly.

## Code formatting by this extension doesn't seem to work.

When you have multiple formatter extensions, be sure to set this
Expand Down

0 comments on commit fe57357

Please sign in to comment.