When you want to prototype an IDE feature (code/ru...
# thinking-together
w
When you want to prototype an IDE feature (code/runtime visualization, search/refactor tool, etc.), how do you start? Are there particularly flexible, plugin-friendly, language-independent IDEs? I’ve been looking at JupyterLab recently, but unfamiliar with ecosystems around more standard IDEs.
r
@Will I would definitely recommend looking into VSCode. They have pretty good support for extensions that could extend the IDE functionality to a certain point. VSCode also exposes a webview (https://code.visualstudio.com/api/extension-guides/webview) API which allows you to embed an IFrame with pretty much any custom UI you want. This opens up a lot of possibilities.
🙏 1
👍 1
k
Can VSCode be used as a live programming environment? Can you work on a VSCode extension in VSCode and try out changes immediately, without restarting?
r
Unfortunately, it's not quite that seamless. You can hit F5 and launch an extension host (which is another VSCode instance where your extension runs) but you have to restart the extension host if you make changes to your extension.
j
Have you considered Emacs?
r
Emacs, Vim, VS Code, and Atom all qualify as "flexible, plugin-friendly, language-independent IDEs". Personally I'd recommend VS Code because that's the way the wind is blowing. But Vim and Emacs are great options if you're otherwise interested in those editors (but if you're not interested in them, their learning curves will distract you from your goals).
p
It's also worth mentioning that Monaco, the code editor component developed for VSCode, can also be used standalone on the web. You might find that the API has a smaller surface area than a full-blown extension. https://microsoft.github.io/monaco-editor/
💡 2
👍 1
r
To @Konrad Hinsen question, I believe all of these environments can dynamically execute code to change their environment (I'm not 100% sure about VS Code, but defintely Vim and Emacs, and I actually wrote a plugin to do this myself in Atom https://atom.io/packages/run-in-atom). With that said, I don't think any of these environments provide special functionality for reloading a whole extension at once? Although that theoretically should be possible. Personally, I find dynamic load great for experimenting, but not as good for building things because it's too common to end up with something that works in your current application state, but that fails when run you restart your environment. I've found a better approach to be excellent state restoration and a really fast startup time, so you can close and re-load your environment and be right where you left off very quickly. (I'd be very interested in hearing if people have had different experiences with that though!)
For the record, I think that adding live coding features to IDEs is more complicated than people realize for a really simple reason: These environments are already so complicated that they're collapsing under their own weight. My own app, Repla https://repla.app/ attempts to address this by moving live coding features to a separate app, there's some details about how these (in development features) will work here https://repla.app/live-coding.html
k
I agree that live coding is best for experimentation, but since that’s what I spend most time on, it matters a lot for me. Emacs is a pretty nice live coding environment, but lacks graphics support. Pharo is even nicer, and does have graphics, but it is less well integrated with the rest of the world.
d
Eclipse and IntelliJ also have decent plugin support. IntelliJ has some kind of language workbench to help make language plugins and compilers. There's also Spoofax for this purpose.