Hacker News new | ask | show | jobs
by dustingetz 4793 days ago
does Dommy provide a pure API on top of the DOM? (e.g., lens based) I don't immediately understand how one would make that performant given that the DOM is a mutable data structure.

edit: WebFUI[1] is one clojurescript project trying to provide a pure interface for dom manipulation; there are others.

[1] https://github.com/drcode/webfui

2 comments

No. We're not trying to do something pure on top of the DOM. That isn't feasible for performant manipulation. Being functional is about more than just immutability.

We use standard manipulation.

> I don't immediately understand how one would make that performant given that the DOM is a mutable data structure.

As a general rule, mutable API's tend to outperform immutable ones.