untangled

NEW CHANNEL: #fulcro
claudiu 2017-05-29T11:05:13.489100Z

@tony.kay The om-css snapshot seems awesome. Surprised by the fast fix in om-next multi-method. but then saw that you fixed it 🙂

claudiu 2017-05-29T11:05:58.495961Z

Seems to work in advanced mode apart from a really strange issue. 😞

claudiu 2017-05-29T11:07:19.508258Z

If in the server I add a om.next then it affects the cljs advanced build for some reason 😞

claudiu 2017-05-29T11:23:54.655871Z

The easiest way to replicate it is just to add [om.next :as om] in the require of the (ns user of user.clj

claudiu 2017-05-29T11:37:34.780747Z

then when i do lein clean && lein cljsbuild once release I get the html without the class just <li> and the <style id="my-css"></style> is empty.

tony.kay 2017-05-29T15:51:38.619387Z

@claudiu you mean in Ssr?

claudiu 2017-05-29T16:06:33.763567Z

not really. Just adding it in dev.clj messes with the clojurescript build.

claudiu 2017-05-29T16:08:52.784443Z

Managed to replicate it in the cookbook example, just by importing in .clj om next. If I remove the import the production build works just fine.

timovanderkamp 2017-05-29T16:29:56.964507Z

Hey @claudiu and other Untangled/om-css users out there. I am currently working with the new version of this library and i'm facing some issues that i would like to improve. Would love to hear your thoughts and suggestions on this. First of, local css-rules and global css-rules are now separated by different protocols. But there are some cases where you would want to add additional css-rules to a classname, for example when you are using an another external component. So what i basically mean is that you have some cases where you want to prevent a keyword to be localised even though it is defined somewhere nested in your local-rules. My suggestion would be to prefix those keywords with a $. Second, multiple classnames now have to be defined like this: {:className (str classA " " classB " " (when condition classC))} I think it would be nice to have a helper function that takes any amount of classnames and merges them together. {:className (css/merge-classnames classA classB (when condition classC))}

tony.kay 2017-05-29T17:06:51.252280Z

@claudiu that is rather strange…no ideas on my end

tony.kay 2017-05-29T17:07:16.255476Z

that should not even be on the classpath during a release build

tony.kay 2017-05-29T17:10:12.277895Z

@timovanderkamp I agree with (1). On (2): I like the idea (though ppl have prob written their own, it won’t hurt to include one). The name is the primary thing. Something shorter would be nice.

tony.kay 2017-05-29T17:11:01.283829Z

what abt & and such?

tony.kay 2017-05-29T17:11:25.286650Z

what other garden -> CSS notations should we be worried about?

tony.kay 2017-05-29T17:12:13.292316Z

probably should go through the docs and explore what we’re going to run into. Or, we can add them as people run into them. The latter makes the library a bit more frustrating.

timovanderkamp 2017-05-29T17:21:20.360344Z

I've looked at the garden selectors to check what would be a problem atm. At a quick look it would not be possible yet to use the CSS combiners and the special selector &.

timovanderkamp 2017-05-29T17:22:33.369626Z

The CSS combiners are +, - and >

timovanderkamp 2017-05-29T17:31:31.438054Z

[:.a {..} [:+.b {..}]] -> .a { .. } .a + .b { .. }

timovanderkamp 2017-05-29T17:32:29.445437Z

What doesn't work atm is that [:+.b {..}] won't be transformed to [:+.namespace_Component__b {..}], as it should be

timovanderkamp 2017-05-29T17:32:38.446496Z

same goes for all the CSS combiners

tony.kay 2017-05-29T17:33:12.450697Z

so as you discover those, throw up issues on github

tony.kay 2017-05-29T17:33:38.454293Z

glad to merge PRs as rapidly as anyone wants to address them

tony.kay 2017-05-29T17:34:33.461377Z

I’m betting one generalization that scans for the set of these like #{"+" ">" ...} will get us a long way

timovanderkamp 2017-05-29T17:35:47.470514Z

yes exactly, we are currently only transforming keywords that start with :.