Ask HN: Alternative to VS Code?

5 points by linkdd 15 hours ago

I am on Windows 11, with WSL2. I have been a user of VS Code for a few years. And I was quite happy with it. I have yet to find another editor with the same level of integration with the languages I work with.

But since the last few weeks, I noticed a change of behavior. The VS Code Remote Server in the WSL starts to eat all the memory. I used to limit my WSL to 4GB of memory, I increased it to 8GB, and it still fills it up, and the swap, causing a huge disk load, making the whole computer extra slow, and the VS Code window becomes unresponsive. Often I either have to kill VS Code, sometimes the WSL itself.

It's so bad it became unusable. And honestly, 8GB for an editor? This is a joke.

I tried neovim, but the days when I enjoyed a vim-based setup are long gone, and honestly the integration with LSP servers is poor at best.

AFAIK, Sublime Text has no WSL integration.

Do you have any recommendations?

armchairhacker 12 hours ago

Seconding IntelliJ. It's not just an IDE for Java: the ultimate edition has everything from GoLand + RustRover + WebStorm + PyCharm (see https://www.jetbrains.com/help/idea/discover-intellij-idea.h... ; it doesn't supersede CLion (C++), AppCode (Swift / ObjC), and Rider (C#)). And it has jump to definition, see documentation, etc. IMO it has more quality-of-life features and they are are faster and fail less than VSCode's.

The main downside of IntelliJ is that it can be memory-intensive and slow, although perhaps not as much as your VSCode. Anecdotally, performance has been fine for me on an M1 Macbook Air, and 4GB more than enough memory, but my projects are probably smaller than yours.

Another option is Zed (https://zed.dev/). Being very new, I doubt it has all of VSCode's features. But it does allegedly work with 100+ languages, and it definitely has jump to definition and view signature (https://zed.dev/features#navigation). Zed should be particularly fast and efficient, and being new will probably gain missing features faster than the others.

  • linkdd 12 hours ago

    I will try IntelliJ then.

    Zed isn't available yet on Windows I think (at least, not prebuilt binaries?)

marshughes 15 hours ago

First of all, you can try to update VS Code to the latest version. Sometimes, memory problems may be caused by bugs in older versions, and new versions often fix these issues. You can also check the installed VS Code extensions. Some extensions may have memory leaks. You can try to disable some non - essential extensions and observe whether the memory usage improves. In addition, regarding the WSL memory settings, you can further optimize the configuration in the .wslconfig file, for example, adjust parameters like pageReporting to better manage memory allocation. For alternative editors, you can consider IntelliJ IDEA. It has good support for a variety of programming languages and has specific configuration options for WSL, which can run well in the WSL environment. Although it is an IDE, if you are used to the rich features of VS Code, the feature set of IDEA may also better meet your needs. Did you encounter any difficulties when trying the above optimization methods for VS Code?

  • linkdd 14 hours ago

    I don't have a lot of extensions actually, my VS Code is pretty much vanilla.

    I'm on the latest version (1.97.2).

    I can try the other memory settings indeed, but I think the culprit is the builtin file watcher. I've stumbled across some similar issues on Github, open for 5 years without a solution :(

    Isn't IntelliJ IDEA for Java/Kotlin? I have a project which is cross-languages: Go+Rust on the backend, Typescript/React on the frontend, Hurl and Python (Robot Framework) for the test suite. And I'd rather not have one IDE per language (which is IIRC what Jetbrains do).

    • codingdave 3 hours ago

      The underlying spirit of marshughes comment sounds on the right track, though - something changed on your system. Maybe it was VS Code, maybe it was something else, but if this is a recent change, you should troubleshoot what actually changed. If it really is VS code, then yes - find a new editor. But I'm not seeing much about what troubleshooting you've done?

      Maybe you've already done this, but if I were you, I'd take note of everything that has been installed and updated in the last month. Walk back installs and updates until your problem goes away, and then you'd know exactly what is causing the problem behavior.

dualogy 7 hours ago

As has happened before, I have to plug this stunningly underhyped editor, TextAdept: https://orbitalquark.github.io/textadept/

Minimalist fast native (not browser-based) code editor for Windows, Mac, Linux, BSD. Both a terminal TUI and a native-GUI version for each. First-class (ie. by same author) LSP package. Fully Lua-scriptable for needs beyond LSP. Succinct C & Lua code-base. FOSS, and matured & maintained ever since 2007. All the basic table stakes (syntax coloring, multi-select-and-edit etc).

Woulda skipped on Sublime back when, had I known about it then.

gregjor 15 hours ago

JetBrains makes several IDEs competitive with VsCode, but not free.

I also stopped using VSCode because of the bloat, which seems mainly caused by node + npm on the remote server. And I've seen it consume all the RAM and too much CPU for an editor.

I know you already rejected Neovim as too much a step back. I went back to plain vim with ripgrep and ctags, ssh/mosh with tmux, my long-time setup, and I'm good with that. No LSP but I can live without that, vim Omni-complete usually good enough.

  • linkdd 14 hours ago

    The ability to autocomplete, and navigate through the code (even my dependencies's code) by the click on a function, the popover showing the documentation/signature of the function i'm going to call. Those are Quality of Life features I'm not ready to give up on.

    As said in a sibling comment, I often work on cross-language projects, I don't recall Jetbrains offering a "one size fits all" IDE.

    • gregjor 7 hours ago

      > The ability to autocomplete, and navigate through the code (even my dependencies's code) by the click on a function, the popover showing the documentation/signature of the function i'm going to call. Those are Quality of Life features I'm not ready to give up on.

      ctags did most of that decades ago. Plain vim has good autocomplete and signature popovers, along with navigating to functions and class definitions. No LSP needed. An LSP will do it better but with sometimes significant overhead.

      As I noted I don't use VSCode or a JetBrains IDE. I know about them and have used them. My setup works language-agnostic, and I also work in multiple languages.

      Possibly useful, at least interesting:

      https://youtu.be/XA2WjJbmmoM

  • jghn 15 hours ago

    Most of them have a free version. For most jobs I've had, I've been AOK using the free version.

  • efortis 15 hours ago

    Not sure which langs the OP needs, but WebStorm is now free for non-commercial use.

ankurdhama 9 hours ago

How about installing VS code in WSL and use that (instead of Windows VS code connecting to WSL, WSL can run linux GUI apps)?

beretguy 14 hours ago

Linux + VSCodium

  • linkdd 14 hours ago

    No, not gonna migrate to Linux.

    I do work and target Windows for a few other projects.

    Also, not trying to start a flamewar, but I've spent too much time tinkering on Linux in the past. There is *always* some hardware compatibility issue, or some missing drivers, and especially with GPUs. Linux works best on a server, or on a VM. At least, that is my experience (and I've been on Linux for more than a decade, be it with either Debian, Archlinux, Gentoo, or Ubuntu).