Live data from Hacker News

Show HN: Build your own Vim emulation for VS Code

johtela.github.io

41–50 of 51 posts

Re: Show HN: Build your own Vim emulation for VS Code

#41

I’ve really wanted to write a Kakoune style layer for VS Code or even a Kakoune style editor that works natively on Windows.

That would be really interesting to me. I have been eyeing Kakoune for a while and love the idea but I'm too invested into VS Code to completely switch editors.

Re: Show HN: Build your own Vim emulation for VS Code

#42
One of the biggest issues with Vim emulation in VSCode is that VSCode has no concept of text objects. Because of this, things like "change inner word" or "paste" will always have to delete text character by character and re-type (in the case of the latter). It's sort of like watching a ghost type. I'm still very impressed with how well it's all working. Atom has AMAZING Vim emulation, but its text rendering engine is different. It'll be interesting to see what the Oni folks come up with.

Re: Show HN: Build your own Vim emulation for VS Code

#43
post #28

Earlier quoted context omitted.

I don't mean to disparage it. Apologies if my post came off that way. I certainly appreciate it and understand emulating vim is not an easy task.

Yeah, I was thinking I may have been a bit aggro there. It's just a coincidence that I only recently embraced IDE life (finally!), and it's in no small part because of this extension. Cheers.

No, I appreciate the call out. My intention wasn't to be negative, but I really was in retrospect. I will be more mindful in the future.

Re: Show HN: Build your own Vim emulation for VS Code

#44
post #13

Earlier quoted context omitted.

For those that are unaware, it’s literally the same system underneath. Vscode talks to language servers to do all the work and they’ve architected the system in such a way that others can talk to them too. Coc.vim provides the plumbing to do that from vim. It’s a great project. Took me a while to get things configured properly but it’s been great for doing all my typescript work.

Is anyone aware of an 'opinionated' neovim distribution? Something like spacemacs or Emacs Live, that takes care of all the configuration work to give a solid basis out of the box. I've been dragging my feet on switching everything to nvim because I don't have 'awhile to get things configured properly' these days.

At least with coc.vim it's literally just a case of picking a vim package manager and using that to install it. Almost no configuration required, apart from `CocInstall`-ing whatever language servers you want.

Re: Show HN: Build your own Vim emulation for VS Code

#45

It's disappointing to see from comments here that there's no true and performant Vim integration for VS Code. It used to be the same thing with Eclipse and JetBrain's IDEs. Whatever Vim plugins existed were slow and falling into the uncanny valley, where they lacked support for many features or did things in slightly unexpected ways. Torn between Vim and effectively Vimless IDEs, I chose to stick to the former and do…

IdeaVim in intellij isn't too bad, it even reads your .vimrc (just source ~/.vimrc in a ~/.ideavimrc file) and while it doesnt have much in terms of vim plugin support, the basic vim vocabulary is there which has been good enough for me.

i had to switch to go/java for work and this has worked better for me than simply writing everything in vim - although vim-go is great, i enjoy being able to run and debug my tests and code in intellij.

Re: Show HN: Build your own Vim emulation for VS Code

#46
For my specific use case the integration is awesome. I can edit text super fast with all vim keybindings. I also appreciate having the easy motion plug-in by default, which I also love. I understand that people who know the depths of vim may lack features they are used to. But for the majority of us it really improves our coding experience, and at the same time we don't spend time struggling to add ide features into vim, because vscode is already a great ide. So when I start using a new file type it just works or there is a plug-in for it. Same with debugger, compiling, and so on.

Re: Show HN: Build your own Vim emulation for VS Code

#47
post #2

This is an interesting approach. I find the popular vim emulation extension (vscodevim) is a bit buggy and has lots of "uncanny valley" gaps. At work I use vscodevim, and at home I use vim with TypeScript plugins. Both approaches have lots of annoyances. Maybe a weekend dedicated to ModalEdit could give me the experience I'm really after. I'm also excited for Oni Vim 2, which is a commercial product who's promise is…

One of the most annoying thing with this extension is that it maintain a different revert history that is conflicting with the normal one. Sometimes you just have to close a file without saving it because undo/redo is broken. And it's extremely slow on medium to large files and it gets slower and slower until you restart vscode. I have a love hate relationship with this extension. It's terrible but vscode without it…

Heh, that’s how I feel after reading this article. I don’t use vim a lot, haven’t gotten used to it. It must be so frustrating always having to chase that “vim experience” in every editor, but never quite getting it.

Re: Show HN: Build your own Vim emulation for VS Code

#49
post #2

This is an interesting approach. I find the popular vim emulation extension (vscodevim) is a bit buggy and has lots of "uncanny valley" gaps. At work I use vscodevim, and at home I use vim with TypeScript plugins. Both approaches have lots of annoyances. Maybe a weekend dedicated to ModalEdit could give me the experience I'm really after. I'm also excited for Oni Vim 2, which is a commercial product who's promise is…

One of the most annoying thing with this extension is that it maintain a different revert history that is conflicting with the normal one. Sometimes you just have to close a file without saving it because undo/redo is broken. And it's extremely slow on medium to large files and it gets slower and slower until you restart vscode. I have a love hate relationship with this extension. It's terrible but vscode without it…

I’ve kind of learned how to juggle the two disconnected undo buffers in my mind. If I want to just go “back in time”, repeating even my previous undo/redos, I use Ctrl-Z. To undo a quick mistake I use Vim’s undo. I guess I treat them like short-term and long-term “undo” actions.

Sounds kind of weird now that I’ve put it in writing. It works for me but YMMV.

Post reply on HN