hoplon

The :hoplon: ClojureScript Web Framework - http://hoplon.io/
2018-02-16T00:22:53.000059Z

@thedavidmeister Thanks. I just discovered :css/*. Still need to upgrade past 7.0.3.

2018-02-16T00:24:35.000128Z

I dont understand the semantics of :class/myelem. What does the symbol after :class/ mean semantically? Why would you reference myelem in it's own definition?

2018-02-16T00:28:03.000146Z

Is there a standard way to manipulate the attrs map from a component declaration. Something like

(myelem (assoc attrs :css #(merge new-css %)))
Or is this more complicated due to Hoplons machinery to maintain dynamic attrs..?

2018-02-16T00:37:34.000091Z

uh, it doesn't mean anything :class/foo is fine

2018-02-16T00:37:47.000051Z

it's just a way to avoid collisions so you don't override like you were saying

flyboarder 2018-02-16T21:29:23.000445Z

@chromalchemy the issue comes in when you are looking to create dynamic attributes, you would need to wrap each component layer in a formula cell to maintain “reactivity” for the attribute. With the :class/* method each layer can implement it’s own attributes without colliding with existing ones, since an element’s attributes are just a map (what david said), when you are making libraries of components this greatly simplifies the code needed.