kylechui / nvim-surround

Add/change/delete surrounding delimiter pairs with ease. Written with :heart: in Lua.
MIT License
3.18k stars 62 forks source link

Could i map like this `map('n', "<leader>'", "ysiw'")` #144

Closed ShiChenCong closed 2 years ago

ShiChenCong commented 2 years ago

Checklist

Is your feature request related to a problem? Please describe. i'd like to map like this

map('n', "<leader>'", "ysiw'")
map('n', '<leader>[', 'ysiw[')
map('n', '<leader>{', 'ysiw{')
map('n', '<leader>(', 'ysiw(')

Describe the solution you'd like successful mapping

Additional context Thank you for the awesome work

kylechui commented 2 years ago

Please see #134 for information. TL;DR you need remap = true, since vim.keymap.set does not enable that option by default.

ShiChenCong commented 2 years ago

works,thank you