mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-14 01:10:02 -04:00
Update CONTRIBUTING.md
This makes it more readable
This commit is contained in:
parent
09c2e6e0a7
commit
35dfd7e1f4
1 changed files with 59 additions and 49 deletions
108
CONTRIBUTING.md
108
CONTRIBUTING.md
|
|
@ -39,64 +39,73 @@ effect on highlighting. We will work on improving highlighting in the near futur
|
||||||
|
|
||||||
|
|
||||||
#### Misc
|
#### Misc
|
||||||
`@comment`
|
```
|
||||||
`@error` for error `(ERROR)` nodes.
|
@comment
|
||||||
`@punctuation.delimiter` for `;` `.` `,`
|
@error for error (ERROR` nodes.
|
||||||
`@punctuation.bracket` for `()` or `{}`
|
@punctuation.delimiter for `;` `.` `,`
|
||||||
|
@punctuation.bracket for `()` or `{}`
|
||||||
|
```
|
||||||
|
|
||||||
Some captures are related to language injection (like markdown code blocks). As this is not supported by neovim yet, these
|
Some captures are related to language injection (like markdown code blocks). As this is not supported by neovim yet, these
|
||||||
are optional and will not have any effect for now.
|
are optional and will not have any effect for now.
|
||||||
`@embedded`
|
```
|
||||||
`@injection`
|
@embedded
|
||||||
`language`
|
@injection
|
||||||
`content`
|
language
|
||||||
|
content
|
||||||
|
```
|
||||||
#### Constants
|
#### Constants
|
||||||
`@constant`
|
```
|
||||||
`builtin`
|
@constant
|
||||||
`macro`
|
builtin
|
||||||
`@string`
|
macro
|
||||||
`regex`
|
@string
|
||||||
`escape`
|
regex
|
||||||
`@character`
|
escape
|
||||||
`@number`
|
@character
|
||||||
`@boolean`
|
@number
|
||||||
`@float`
|
@boolean
|
||||||
|
@float
|
||||||
|
```
|
||||||
|
|
||||||
#### Functions
|
#### Functions
|
||||||
`@function`
|
```
|
||||||
`builtin`
|
@function
|
||||||
`macro`
|
builtin
|
||||||
`@parameter`
|
macro
|
||||||
|
@parameter
|
||||||
|
|
||||||
`@method`
|
@method
|
||||||
`@field` or `@property`
|
@field or @property
|
||||||
|
|
||||||
`@constructor`
|
@constructor
|
||||||
|
```
|
||||||
|
|
||||||
#### Keywords
|
#### Keywords
|
||||||
`@conditional`
|
```
|
||||||
`@repeat`
|
@conditional
|
||||||
`@label` for C/Lua-like labels
|
@repeat
|
||||||
`@operator`
|
@label for C/Lua-like labels
|
||||||
`@keyword`
|
@operator
|
||||||
`@exception`
|
@keyword
|
||||||
`@include` keywords for including modules (e.g. import/from in Python)
|
@exception
|
||||||
|
@include keywords for including modules (e.g. import/from in Python)
|
||||||
`@type`
|
|
||||||
`builtin`
|
|
||||||
`@structure`
|
|
||||||
|
|
||||||
|
@type
|
||||||
|
builtin
|
||||||
|
@structure
|
||||||
|
```
|
||||||
### Locals
|
### Locals
|
||||||
|
```
|
||||||
`@definition` for various definitions
|
@definition for various definitions
|
||||||
`function`
|
function
|
||||||
`method`
|
method
|
||||||
`var`
|
var
|
||||||
`macro`
|
macro
|
||||||
`type`
|
type
|
||||||
`field`
|
field
|
||||||
`doc` for documentation adjecent to a definition. E.g.
|
doc for documentation adjecent to a definition. E.g.
|
||||||
|
```
|
||||||
|
|
||||||
```scheme
|
```scheme
|
||||||
(comment)* @definition.doc
|
(comment)* @definition.doc
|
||||||
|
|
@ -104,7 +113,8 @@ are optional and will not have any effect for now.
|
||||||
name: (field_identifier) @definition.method)
|
name: (field_identifier) @definition.method)
|
||||||
```
|
```
|
||||||
|
|
||||||
`@scope`
|
```
|
||||||
|
@scope
|
||||||
`@reference`
|
@reference
|
||||||
|
```
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue