3 ms·
i don't think i'm confusing anything. Clojure programmers love their persistent data structures, and in a browser environment, the most important data structure
by dustingetz 14y ago
i don't think i'm confusing anything. Clojure programmers love their persistent data structures, and in a browser environment, the most important data structure - the document model object - is not persistent and cannot be made persistent in a performant manner because it is a native api.
there is ongoing research into dom manipulaton in clojurescript - Conrad Barski presented one approach[1] at Conj 2012 where the dom is mirrored in clojurescript data structures, and then 'synced' with the dom - so that way the imperative ickyness is tucked away in the sync method - it remains to be seen if that can be made fast enough until we get a native persistent interface to the dom.
[1] https://github.com/drcode/webfui https://github.com/drcode/webfui
- vemv 14y agoCharacterizing side-effects as a series of supposedly functional transformations doesn't sound quite alright to me. That said I'm curious about such an approach.
- dustingetz 14y agoModeling side effects as transformations on data is what functional programmers do all day. I'm not talking about monads - simple things like inserting keys into a map and manipulating collections does not rely on side effects in functional languages.