Our great sponsors
-
coc.nvim
Nodejs extension host for vim & neovim, load extensions like VSCode and host language servers.
-
coc-tsserver
Tsserver extension for coc.nvim that provide rich features like VSCode for javascript & typescript
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
This is extracted directly from the CoC.nvim Example Configuration. I've made some tweaks and annotated some things that work for me.
I've then also installed coc-tsserver by running:
As you can see, I've commented it out. That is because as great as it is, it comes at an expense. First, it was often auto-completing words unexpectedly when what I was trying to do was create a new line. For instance, in Ruby files, I'd type do for a block and then hit enter to go the first line of the block's body. Instead, it would auto-complete do to does. Second, this overriding of the enter key was clashing with vim-endwise which I depend on for Ruby development.
As an avid user of vim-unimpaired, I love these next two lines. These two bindings allow me to jump forward and backward to the next diagnostics marker. For instance, in a TypeScript file, if I change a type definition, that causes some type errors throughout the file, I can quickly jump to those spots in the file.