coc.nvim
coc.nvim copied to clipboard
Add support for object movement
Is your feature request related to a problem? Please describe.
I'm always frustrated on object (e.g., function, method, class) movements in Vim,
Vim has ]]
, [[
,..., ]m
mappings; however it's very weak and only suit on some limited cases.
I know CoC provides :CocCommand document.jumpToPrevSymbol
, but it only works on variable-like symbols.
Describe the solution you'd like Provide some commands or actions or mappings to jump to next object, for example:
" users may map to `]f`
:CocCommand document.jumpToNextFunction
" users may map to `]m`
" (I think CoC can provide better version than Vim's)
:CocCommand document.jumpToNextMethod
" users may map to `]c`
:CocCommand document.jumpToNextClass
" users may map to `]n`
:CocCommand document.jumpToNextNamespace
I thinks it will be very useful and more convenient than moving by outline list/window.