Fork me on GitHub
#re-frame
<
2022-04-20
>
joefromct00:04:42

Hi, has anyone come across this:

ReactDOM.render is no longer supported in React 18
Any ideas where to reconcile this?

joefromct00:04:25

The only relevant js thread I could find was very recent and here: https://stackoverflow.com/questions/71668256/deprecation-notice-reactdom-render-is-no-longer-supported-in-react-18 Maybe this belongs in a reagent chat somewhere, apologies if that's the case.

joefromct01:04:24

Ah, i guess here is my answer: https://github.com/reagent-project/reagent/pull/554 /solve or /close or something (sorry new to slack)

colinkahn17:04:16

I'm new to re-frame 10x and am trying to get it to ignore a polling event. I'm using the "Traces" view to see the list of events, and I am trying to use the settings panel "Ignore epochs for: ", adding the fully qualified keyword as the event-id. This doesn't seem to be working though (I still the the events show up in the "Traces" view).

p-himik17:04:48

Which version are you using?

colinkahn18:04:01

0.4.3, looks like it's up to 1.2.6... I'll see about upgrading.

colinkahn18:04:29

But the method I mentioned above should work?

p-himik18:04:07

Yep, I just checked.

colinkahn18:04:18

Thanks for checking!

mathias_dw18:04:33

hi, since there doesn’t seem to be a re-com-specific channel, I’m posting it here: In re-com’s typeahead component, I need to clear the contents in the on-change event, since I’m putting the selected search terms as tags next to the typeahead field, and there can be multiple search terms. Is there a way to easily do that?

lispers-anonymous15:04:24

I don't think re-come is related to re-frame at all. It's written entirely with reagent. You might also try to post in the #reagent channel

mathias_dw15:04:51

it’s written by the same author (at least the same github handle), but you’re right it doesn’t depend on re-frame. I would be surprised to see re-com users that aren’t re-frame users, though 🙂

joefromct12:04:51

Hi, so if i'm understanding it correctly, it's very similar to the demo however rather than replacing the edn map on the right you probably want to conj on-change and build up an array of maps?

mathias_dw12:04:15

Yes, but that part is not the problem. I can easily get the content out and add the results next to the input field. The problem is that the last selected value stays in the input field, and it can’t be cleared programmatically. It’s annoying, because my users then need to delete the contents manually before starting the next query…

joefromct15:04:28

oh... hmm. Maybe you could try to use a reagent atom locally to that component, and not transition to the app-db until the on-change.

joefromct15:04:39

I'm not an expert but was just working on something very similar.

joefromct15:04:14

If seems like you need a second "place" to hold the intermediate state as you conj up the good stuff.

joefromct15:04:43

Maybe that second place could be a reagent/atom in a let binding, for maybe a type-2 form in re-frame? then your onclick might do something like

{:on-click (juxt #(dispatch ...)
                  #(reset! intermediat-val "") ;; <-- reset the type-ahead}

joefromct15:04:09

let me know if that makes sense or not

mathias_dw19:04:06

Hi, thanks for your reply! I did try that, passing an atom to the model parameter and then setting it to the empty string in the on-change handler, but no success :(

joefromct19:04:37

hmm... do you have a gist you can share somewhere? I'll take a look when i get a minute.

mathias_dw19:04:24

I'm also typing on my phone, it's Friday evening here :)

joefromct19:04:47

no worries, i'm going to try to be on slack a bit more. the internet gets lonely. msg me later.

mathias_dw19:04:49

I'll send it tomorrow, thanks!

👍 1