When is `Cmd` actually processed?

Great explanation! Thank you! I believe that Evan (or maybe someone else) mentioned that this is going to change (maybe optionally?) in 0.19 allowing you to run Cmds (or perhaps this was for ports) in the same tick as the code that called it. This was in the context of supporting certain events that require code to be run sync (as opposed to async via setTimeout or requestAnimationFrame). I’ll see if I can find the link when I’m not on my phone, but curious if I’m understanding that correctly…

UPDATE: I did find the post in question, and Evan actually said that ports are changing to be able to be run as direct event handlers, not Cmds.

1 Like