Fork me on GitHub

Does the current-route! function mentioned at exist? I don't see it in a github search. Thanks


Use the source. Double-tap of shift in IntelliJ, type current-route, double tap shift again to get “include non-project items”:


Or just jump to source from a require of the DR ns Or clone the repo and try git grep Or use (thanks to @U0522TWDA!!! So nice)


Thanks @U0CKQ19AQ However, I'm asking about:

Additional useful functions are:

(current-route! component-or-app starting-component)
Returns a vector of the path components on the current (live) route starting at the given starting-component. If you use your root component it will be the absolute path, and using some other component router will give the relative path from there.


Note the trailing !


yes, that doc is incorrect

👍 3

I have a n00b question. I am working on Fulcro with React Native. I have the app rendering properly and am able to see controls.. I am successfully loading queries in to my local app db -- I can seee the data with Fulcro inspect. However, the forms on the simulator are blank and my debugging statements show that props are empty. I am sure that i missed something or am doing something wrong. Could someone point me in the right direction? Thanks in advance!


You have to join the loaded data to your view graph. Initial data composes it all together for what is there at app startup, but if you’re loading data you use targeting to create the edge in the UI. If props are nil, here is the way to diagnose it every time: 1. Go to DB Explorer tab in Inspec 2. Find your root data node 3. Follow the graph by clicking to follow your data graph in the same way your UI joins the target in…root through router current route through X , Y, etc. At some point you will either: Discover that your data graph isn’t connected and that you should have added :`target` to your load or merge, OR discover that you didn’t compose the query to match your data graph.


Thank you @U0CKQ19AQ. I'm sorry to bother you.


no problem. Everyone asks this same question at some point, and it’s funny how silly simple the answer always is: Fulcro is the only lib I’m aware of where the View = F(state) in such a literal way. If the F, which is just the query, can follow the graph in state, which it does literally by walking idents, then you’ll get the right props. The one additional screw-up is if you don’t pull the props out and pass them to the child. That’s also a possible thing to look at, but much rarer mistake since the defsc macro tries to error-check your destructuring of props for typos (because it was a common error that we could detect and help with)

Aleksander Rendtslev02:02:54

Hi @UGNMGFJG3 , I'm also in the process of building a React Native app with Fulcro, and I've been through a lot of the same gotchas (where Tony helped me out). Let me know if you'd like to jump on a call and compare notes? I'd be happy to show you what I've gotten so far.


Hi @U01DH13SK8E -- let's compare notes soon. I have made some progress and would like to find someone to talk to about where I am headed.

Jakub Holý (HolyJak)21:02:55

Thanks to my awesome mentees, I am starting a new series, "Fulcro Gotchas". The beginning is here: If you have some pitfalls and misconceptions of your own that you would like help others to avoid, let me know!

❤️ 9

Note to self: Definitely don't mistake ident for indent 😄

😱 3
Jakub Holý (HolyJak)13:02:46

Thank you, Tony! Updated.