Fork me on GitHub

I seem to be running into issues with uism/trigger-remote-mutation on safari. works fine on chrome though.


anyone else running into this?


oops, looks like things weren’t working because of the actor needing to be mounted


Though i still find it odd that it the requests happened in chrome and firefox anyway, but not safari


Does colocated css get inserted on the fly, or is everything there on page load?


you insert it explicitly


so you can do both


Right, but say I have a style that is conditional on something on state. Does it insert extra styles dynamically when state updates, or is every branch precalculated and inserted on page load?


I need to be able to generate the exact same styles to insert inline server side (not necessarily for server side rendering)


I don’t think Fulcro supports dynamic CSS


you instead should declare your styles using component local css + localized class names


Ok, I actually don't want dynamic css, because i don't want the overhead and i want to be able to reuse the css outside of a react app


Howdy all, I have a form with a select as the first element. The select is working fine and loading options from the server no problem. I'd like some of the other form inputs to provide defaults based on the chosen select option at the top but I'm having a difficult time with this. Is there an example that anyone can provide? I'm just using basic html, no bootstrap or anything fancy.


@jackson.reynolds So, you select something in the first thing, and that should trigger the load of defaults for the others, right? So, each of those inputs has some query for their ‘defaults’…so, onChange of the first one, trigger loads that target the others (using the newly selected value)


@danielstockton once the app is running and you inject the css onto the page, then anything on the page will see it….if you’re saying you want to export that css for other pages (that don’t even use React) then you can do that as well, though there isn’t any built-in function from Fulcro…use cljc for your components and you can pull the garden stuff from the components in CLJ, and use garden’s mechanisms to translate it to css…so on a server you could just serve that as a CSS resource from a URL, etc.


(live) update semantics are up to you…some of the default injection stuff tries to prevent refresh for efficiency.


Ok @tony.kay, sounds good, and yes, that was what I was looking to do. I didn't like how cljss injected things dynamically, and I found it very difficult to compose styles.


@tony.kay I understand at a high level.. the default config data I want loads fine from the server inside the onChange, it's getting the other inputs to refresh with new data that isn't happening.


you need to add a follow-on read to the transaction ( of :refresh for load) that includes the keywords on which that data is queried…that’s how fulcro figures out what needs to be refreshed in the UI


yep. Tried :refresh with the load. Tried refresh!. There's something fundamental I'm missing.


:target sometimes changes things in :ui/root {..} sometimes changes things in the root of the db?


:target is simply an assoc-in path. :refresh is a vector of keywords (that appear in component queries somewhere). Fulcro keeps an index of which components query for which keywords…so it can derive the list of mounted components fomr that.