chore(nvim): use treesitter textobj

main
sudo pacman -Syu 2023-07-26 00:39:56 +07:00
parent a6a793eb9d
commit 04a85dc864
1 changed files with 22 additions and 0 deletions

View File

@ -391,6 +391,28 @@ require("lazy").setup({
end,
},
-- https://github.com/nvim-treesitter/nvim-treesitter-textobjects
{
"nvim-treesitter/nvim-treesitter-textobjects",
dependencies = {
"nvim-treesitter/nvim-treesitter-context",
},
config = function()
require("nvim-treesitter.configs").setup({
textobjects = {
select = {
enable = true,
lookahead = true,
keymaps = {
["af"] = "@function.outer",
["if"] = "@function.inner",
},
},
},
})
end,
},
-- https://github.com/neovim/nvim-lspconfig
{
"neovim/nvim-lspconfig",