Fork me on GitHub

@danielcompton thanks for the re-frame-trace release, it works now.


Hi, I'm using cljs-ajax in a re-frame project. When POSTing using ajax.core/ajax-request (via http-xhrio) the namespace is being stripped from qualified keywords when the JSON request is sent. When using ajax.core/POST the namespaces are left intact. So

:params {:test.user.model/email ""}
is being posted as JSON
{"email:" ""}
. Is there a config option I'm missing?


We use the other API in cljs-ajax


I think it’s ajax-request?


It's the ajax-request api that is dropping the namespaces.


Hi! Me and my team released yesterday a tiny lib that has a functionality similar to js’s Promise.all() feature. This is our first attempt to contribute to the community with code so any criticism and further guidance will be very much appreciated simple_smile


What are routing / history libraries that work well with re-frame? I have been using accountant to manage the browser history but I am having some trouble with scroll restoration. (It doesn't scroll to top when navigating to a new page and it doesn't properly restore the scroll position when pages have different heights.) Are there examples that deal with this issue? Ideally I would also like the location hash to act like in plain html (jump to anchor on page).


@davidst we use pushy with bidi


pushy does the url/html5history stuff, and you give it a callback to bidi which resolves the url and parameters, and then we push that into re-frame


@davidst I use bidi with accountant and I don't have those issues


pushy seems to do roughly the same as accountant


it's a bit silly but let me describe one of the issues: if I scroll down and click on a link that is handled by accountant/pushy then the new page loads (as desired) but the scroll position is maintained (not desired; it should scroll to the top of the page)


I'd try: - to force full re-rendering on route change (by assigning a key with gensym to the root component). see if that fixes the issue, and if it does, find a better way - to simply use the JS call for scrolling to the top, every time the route changes


Right now I make JS calls to scroll to the top when a new page loads. However it is not quite the right behavior. If the new page loads because of a popstate event (back button), the previous scroll position should be restored (at least that's the vanilla html behavior). I was hoping that there is a library that works with re-frame and more faithfully sticks to the navigation behavior for plain html


Had the same requirement and opted for @joelsanchez1st point but it still doesn’t solve the popstate issue


you could try to save the scroll position before a route change and then have a listener for popstate events, and apply that scroll position...or smth