3 ms·
> So we looked for smaller alternatives, like virtual-dom and mercury. The documentation for virtual-dom was slim and we didn’t think the API for mercury was ve
by fiatjaf 12y ago
> So we looked for smaller alternatives, like virtual-dom and mercury. The documentation for virtual-dom was slim and we didn’t think the API for mercury was very user friendly.
Really? You found that it was better to write everything from scratch instead of modifying mercury for your use (thus making use of the very good virtual-dom library)? Do you know that the whole mercury source code[1] is only 126 lines of code?
Perhaps you should also know that your library usage examples, in the end, look just like mercury usage examples.
[1]: https://github.com/Raynos/mercury/blob/master/index.js https://github.com/Raynos/mercury/blob/master/index.js
- deleted 12y ago[deleted]
- jaltekruse 12y agoI think that you are pointing at the wrong file, it looks like the library is actually around 4k lines. The point may still be valid, but it was not a trivial codebase to fork and they seem to have some architectural goals that they didn't think any of the current libraries were well suited to work with. https://github.com/Raynos/mercury/blob/master/dist/mercury.js https://github.com/Raynos/mercury/blob/master/dist/mercury.j...
- darklajid 12y agoStumbled upon this [1] in their Readme: mercury is lean, it's an weekend's read at 2.5kloc. (virtual-dom is 1.1kloc, an evening's read.) 1: https://github.com/Raynos/mercury https://github.com/Raynos/mercury
- tel 12y agoHaving attempted to read virtual-dom several times I highly disagree with it being an "evening's read". It is highly complex, idiosyncratic, has a number of difficult to grok internal conventions, and at least a few large algorithms with next to no documentation. I think a lot of people deservedly like it's API, but it is far from an easy read.