Files
absolute-vim/lua/absolute/after/treesj.lua
David Ibia 4f0f762caa feat(treesj.lua): add treesj.lua file to enable toggling of Treesitter Join functionality
The treesj.lua file is added to the project to enable the toggling of Treesitter Join functionality. The `tsj.setup` function is called to configure the plugin with the option `use_default_keymaps` set to `false`. This ensures that the default keymaps provided by the plugin are not used.

A keymap is set using `vim.keymap.set` to bind the `<leader>m` key combination in normal mode to the command `TSJToggle`. The `opts.desc` option is set to provide a description for the keymap.

This change allows users to toggle the Treesitter Join functionality using the `<leader>m` key combination in normal mode.
2024-01-14 04:01:44 +01:00

12 lines
196 B
Lua

local tsj = require("treesj")
tsj.setup({
use_default_keymaps = false,
})
local opts = {}
opts.desc = "Toggle Treesitter Join"
vim.keymap.set("n", "<leader>m", "<cmd>TSJToggle<CR>", opts)