Closed asmala closed 10 years ago
@asmala Kioo does support attaching two transforms to the same node so I suspect something odd is going on here.
This is fixed in the 0.4.1-SNAPSHOT out on clojars now. On smaller note, you should be using set-style vs setting the attribute.
Thanks for the fast fix. And yes, you're quite right about set-style
over set-attr
. Good to set that straight for posterity. :-)
It appears that kioo cannot do two transformations on the same node. Doing so produces a rather spectacular parse error during cljs compilation.
Take for example
/example/om/src/kioo_example/core.cljs
and add a transformation targeting all divs:The offending piece of code in the generated JavaScript appears to be:
The README doesn't seem to mention multiple transformations on one node as a limitation, but I may be missing something. In some cases,
(do-> …)
is an acceptable workaround, but in other cases this leads to rather verbose code. Here's a case that could benefit from multiple transformations on one node: