This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-03-05
Channels
- # beginners (229)
- # cider (54)
- # cljs-dev (187)
- # cljsrn (1)
- # clojure (187)
- # clojure-dev (5)
- # clojure-italy (31)
- # clojure-losangeles (1)
- # clojure-russia (3)
- # clojure-spec (76)
- # clojure-uk (29)
- # clojurescript (94)
- # cursive (18)
- # datascript (8)
- # datomic (26)
- # docker (6)
- # emacs (19)
- # figwheel (6)
- # fulcro (41)
- # garden (1)
- # graphql (1)
- # hoplon (33)
- # jobs (1)
- # jobs-discuss (1)
- # lein-figwheel (14)
- # leiningen (7)
- # nrepl (10)
- # nyc (1)
- # off-topic (2)
- # onyx (2)
- # parinfer (25)
- # portkey (6)
- # powderkeg (1)
- # protorepl (1)
- # re-frame (14)
- # reagent (14)
- # shadow-cljs (31)
- # spacemacs (3)
- # test-check (33)
- # uncomplicate (1)
- # unrepl (40)
- # vim (5)
- # yada (16)
@candera yes, many of them are irrelevant to the mutation observer, so you can attach the attribute anywhere and it doesn’t matter
Requires hoplon 7.2?
oh ancestors no children yes
Yeah, I would think you’d need to know about ancestors to understand when you’ve been added to the DOM…
I think thats the one you are looking for, but I would need to RTM again
I don’t think there’s a great way to always know ahead of time who your parent is going to be and have him watch for you being added. I want to put something on the node that’s outside the DOM.
@candera http://ryanmorr.com/using-mutation-observers-to-watch-for-element-availability/
yesterday I read about another interesting alternative technique to MutationObservers. http://www.backalleycoder.com/2012/04/25/i-want-a-damnodeinserted/ https://github.com/naugtur/insertionQuery
maybe that would help?
That appears to require a selector. I assume that means you know where you’re going to add the element.
I don’t really want to have to bake global knowledge of the document. I just want a darn event to fire. 🙂
Fair enough, but a selector could be anything right?
you could use gensym and a custom attribute to find it
:thumbsup:
np, just thinking out loud 😛
It’s the usual tangled Javascript callback mess, so I’m trying to track if it calls code on every single mutation of the DOM. That might be an issue.