1/13/2023 0 Comments Coc snippetsnmap qf ( coc - fix - current ) " Map function and class text objects " NOTE: Requires 'textDocument.documentSymbol' support from the language server. nmap ac ( coc - codeaction ) " Apply AutoFix to problem on the current line. " Example: `aap` for current paragraph xmap a ( coc - codeaction - selected ) nmap a ( coc - codeaction - selected ) " Remap keys for applying codeAction to the current buffer. autocmd User CocJumpPlaceholder call CocActionAsync (' showSignatureHelp ') augroup end " Applying codeAction to the selected region. autocmd FileType typescript, json setl formatexpr = CocAction (' formatSelected ') " Update signature help on jump placeholder. xmap f ( coc - format - selected ) nmap f ( coc - format - selected ) augroup mygroup autocmd ! " Setup formatexpr specified filetype(s). nmap rn ( coc - rename ) " Formatting selected code. autocmd CursorHold * silent call CocActionAsync (' highlight ') " Symbol renaming. expand (' ') endif endfunction " Highlight the symbol and its references when holding the cursor. expand (' ') elseif ( coc # rpc # ready ()) call CocActionAsync (' doHover ') else execute '!'. nnoremap K : call show_documentation () function ! s: show_documentation () if ( index (,
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |