Files
vscode-extension-samples/semantic-tokens-sample/README.md

27 lines
690 B
Markdown
Raw Permalink Normal View History

2019-12-09 15:39:21 +01:00
# Semantic tokens sample
This is an extension sample showing a very simple semantic tokens provider. This semantic tokens provider always returns all the tokens in a file.
2020-05-01 17:16:40 +02:00
For more background on semantic highlighting read [here](https://code.visualstudio.com/api/language-extensions/semantic-highlight-guide)
2020-01-17 16:41:22 +01:00
2019-12-09 15:39:21 +01:00
![Screenshot](demo.png)
## How to run
Launch the extension and open the file `sample/sample.semanticLanguage` and use the following settings:
2021-07-10 12:02:11 +07:00
```jsonc
2020-05-01 17:16:40 +02:00
"editor.semanticTokenColorCustomizations": {
"enabled": true, // enable for all themes
"rules": {
"*.static": {
"foreground": "#ff0000",
"fontStyle": "bold"
},
"type": {
"foreground": "#00aa00"
}
2019-12-09 15:39:21 +01:00
}
}
```