nvim: big auto pairing update: update nvim-autopairs configurarion, add nvim-ts-autotag, add nvim-treesitter-endwise
This commit is contained in:
parent
8f92613c6f
commit
c715fef437
1 changed files with 28 additions and 1 deletions
|
@ -286,9 +286,36 @@ return require('packer').startup({function()
|
|||
use { -- Quote pairing
|
||||
'windwp/nvim-autopairs',
|
||||
config = function()
|
||||
require('nvim-autopairs').setup()
|
||||
-- If you want insert `(` after select function or method item
|
||||
local cmp_autopairs = require('nvim-autopairs.completion.cmp')
|
||||
local cmp = require('cmp')
|
||||
cmp.event:on(
|
||||
'confirm_done',
|
||||
cmp_autopairs.on_confirm_done()
|
||||
)
|
||||
require('nvim-autopairs').setup({
|
||||
-- check_ts = true,
|
||||
-- map_c_h = true,
|
||||
-- map_c_w = true,
|
||||
})
|
||||
end
|
||||
}
|
||||
use { -- ts-autotag: automatically close html tags
|
||||
'windwp/nvim-ts-autotag',
|
||||
config = function()
|
||||
require('nvim-ts-autotag').setup()
|
||||
end
|
||||
}
|
||||
use { -- endwise: auto add 'end' keyword
|
||||
'RRethy/nvim-treesitter-endwise',
|
||||
config = function()
|
||||
require('nvim-treesitter.configs').setup {
|
||||
endwise = {
|
||||
enable = true,
|
||||
},
|
||||
}
|
||||
end
|
||||
}
|
||||
use { -- accelerated jk movement
|
||||
'rhysd/accelerated-jk'
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue