Backend independent Halogen-vdom

I have started working on a backend independent version of halogen-vdom, which basically drops the web-html dependency and JS FFI. This means that it can be compiled to languages other than JS, and can work with other native rendering backends (native/desktop/mobile).

It provides a simple, react-reconciler inspired, hostconfig (https://github.com/ajnsit/purescript-halogen-vdom-independent/blob/master/src/Halogen/VDom/HostConfig.purs#L14) to interface with any rendering backend as long as its api resembles manipulating a persistent DOM tree (which is most of them).

The plan is to be able to use all of the react backends (see https://github.com/chentsulin/awesome-react-renderer) with minimal work. I already have this working with Concur (unreleased), and am currently in the process of experimenting with native desktop/mobile app bindings.

Iā€™m not familiar enough with Halogen to say how much work it would be to integrate this into Halogen. Perhaps someone more familiar can comment? CC: @natefaubion, @thomashoneyman.

Criticism/help appreciated!

12 Likes