bryphe
Joined 9 years ago
Joined 9 years ago
There's a cool non-Onivim usage of it called Paravim [2] (and the same author also used it for Vim-Cubed [3])
- [1] https://github.com/onivim/libvim/blob/master/src/libvim.h
Revery supports the same FFI as OCaml [1] - C-style linking. I believe Rust would be straightforward to integrate that way - I'm not sure about C#.
- [1] https://caml.inria.fr/pub/docs/manual-ocaml/intfc.html
I think it's so cool that you can take the ideas of ReactJS - functional programming applied to UI - but then have a language (ReasonML [2]) that is essentially purpose built for it, with OCaml [3] powering it under the hood - a functional programming language that's been significantly invested in, both in academia and industry. And to be able to take React-the-Idea, compile it cross-platform, to native-code... and ship.
- [1] Jordan Walke - React to the Future: https://www.youtube.com/watch?v=5fG_lyNuEAw
- [2] https://reasonml.github.io/
- [3] https://ocaml.org/
This is one of the biggest pieces feedback we've received both the tabs / splits in particular [1], and the more general issue of broader Vim compatibility [2].
We actually use a forked Vim implementation under the hood (libvim [3]) - as the modal-editing engine. So Onivim, in theory, _could_ support everything. The main issue is 'wiring up' features from libvim to our front-end.
We'll be focusing on this in our next milestone (July-Sep) - with the high level goals of supporting more traditional Vim workflows, Vim tab support, along with VimL plugin support and init.vim/vimrc compatibility.
Ultimately it's a prioritization problem - so having feedback like yours is really helpful, so that we can focus on the right priorities for that work.
- [1] https://github.com/onivim/oni2/issues/592
It's inspired by ReactJS, and has a similar API, but actually compiles to native code (not javascript). So you have a React-like developer experience, but with native perf.
Would much rather work on bug fixes and features! Just a necessary evil to be able to fund development. In an ideal world - could just write open source software and not worry about paying bills.
I don't think this is a fair characterization. We've made significant investments in both Neovim and Vim, and carefully considered the trade-offs.
> Guts of it is that Neovim didn't play nicely with their OCaml build and Vim did
This was a smaller consideration - but more fundamentally, the model Neovim uses for input - queuing it on an event loop and handling it asynchronously - is at odds with what we required - to be able to process the input -> handle updates synchronously.
There was a significant amount of incidental complexity in the architecture of our V1 to fit that asynchronous model - we wanted to avoid that for V2, and we switched to Vim because it fit that model.
The extension host is larger than just handling language services - it handles additional functionality, like source control, menus, language configuration - the full protocol is defined here: https://github.com/microsoft/vscode/blob/master/src/vs/workb...
We aim to integrate with that back-end extension host process - in other words, to support the `vscode` extension API surface, not just language support.
Because of the ubiquity and popularity of VSCode - the extensions tend to have significant investment and be of very high-quality, so we'd like to be able to leverage that wholesale.
We wanted a model where, unlike completely proprietary licenses, the source code could be available - and, worst case, if something happened to the project - users could still have full access to it. And that all the work is eventually available in general.
Our first OSS drops - from 18 months ago - are coming in next month (July 2nd), so that'll be exciting. It will be interesting to see how it works out.
Still early days - and a lot of work - to realize our vision for this project :) But I'll be around to answer questions.
Oni maintainer here! I agree - I get stressed out sometimes when this gets posted to HN for that reason ;)
I'll piggyback here because this is near the top, but I'll give a couple quick reasons why Electron was chosen for this project:
- Development speed As mentioned in another comment, the React ecosystem has some excellent development tools around hot-reloading / live-reloading. I never found this sort of 'live-reload' workflow in any of the C/C++ toolchains I've used. (Would be interested if that has changed!)
For a very small team, this is an important consideration! It's the difference between Oni existing as an Electron app vs. not existing at all.
- Developers Oni is an open source project, and I open-sourced it because I wanted help building it (and I've been fortunate to work with some amazing contributors [1]). When you look at the last StackOverflow Developer Survey [2], web tech is overwhelmingly at the top - if I want help, I should pick the tech stack that has the broadest appeal.
Every editor is an exercise in trade-offs, and of course Electron brings trade-offs of its own. Oni is an experiment in a different (not necessarily better, because that's subjective and relative to each person's workflow) set of trade-offs than other editors - an attempt to bring together the "modern" functionality of editors like Code/Atom with Vim. It resonates with some people, but it's not going to be for everyone, and that's OK.
Even if you don't use Oni or agree with the tech stack, these sorts of experiments are important, because if new ideas or workflows work well... they can find their way into your editor of choice, too.
One other note - I focused a lot on Electron, but the project wouldn't be here without neovim, either! They've done excellent work, and there is quite a variety of front-ends - so even if Oni isn't your thing, I'd encourage to check out that project as well as some of the front-ends for it [3].
[1] - https://github.com/onivim/oni/graphs/contributors
[2] - https://insights.stackoverflow.com/survey/2018/#technology
[3] - https://github.com/neovim/neovim/wiki/Related-projects