1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
return {
"nvim-treesitter/nvim-treesitter",
build = ":TSUpdate",
opts = {
highlight = {
enable = true,
additional_vim_regex_highlighting = false,
},
ensure_installed = {
"go",
"lua",
"javascript",
"typescript",
"json",
"yaml",
"python",
"bash",
"markdown",
"html",
"css",
"rust",
"templ",
},
ignore_install = { "gdhsader", "phpdoc", "org" },
indent = { enable = true },
auto_install = true,
sync_install = true,
incremental_selection = {
enable = true,
keymaps = {
init_selection = "<C-space>",
node_incremental = "<C-space>",
scope_incremental = false,
node_decremental = "<bs>",
},
},
textobjects = {
select = { enable = true, lookahead = true },
move = {
enable = true,
goto_next_start = { ["]f"] = "@function.outer", ["]c"] = "@class.outer", ["]a"] = "@parameter.inner" },
goto_next_end = { ["]F"] = "@function.outer", ["]C"] = "@class.outer", ["]A"] = "@parameter.inner" },
goto_previous_start = {
["[f"] = "@function.outer",
["[c"] = "@class.outer",
["[a"] = "@parameter.inner",
},
goto_previous_end = { ["[F"] = "@function.outer", ["[C"] = "@class.outer", ["[A"] = "@parameter.inner" },
},
},
},
dependencies = {
{ "nvim-treesitter/nvim-treesitter-textobjects" },
{
"nvim-treesitter/nvim-treesitter-context",
opts = {
enable = true,
mode = "topline",
line_numbers = true,
},
},
{ "windwp/nvim-ts-autotag" },
},
}
|