chenglou changed the topic of #reasonml to: facebook.github.io/reason/. Public channel logs at irclog.whitequark.org/reasonml. Discord: discord.gg/reasonml
xkapastel has quit [Quit: Connection closed for inactivity]
magopian has joined #reasonml
<magopian> hi o/
<magopian> i'm reading through https://reasonml.github.io/reason-react/docs/en/state-actions-reducer.html#async-state-setting and don't understand why the reducer in "didMount" returns a ReasonReact.NoUpdate while it's obviously doing an update to self.state.timerId
<magopian> is that an error in the documentation, or am I missing something?
<magopian> oh, wait, it's mutating the thing, instead of asking for a proper state update. Not sure how i feel about that
<reynir> Yea that seems odd to me too, although I know nothing about react
<reynir> Couldn't this result in a mess of copies of the mutable field?
<reynir> magopian: Maybe you can ask in an issue on the github page?
<magopian> i believe they use that for "instance variables": https://reasonml.github.io/reason-react/docs/en/instance-variables.html
<magopian> so it's kind of in-between a state and a props or something along those lines? It's a bit confusing
<reynir> I'm a bit busy at work, don't really have time to read the documentation - maybe later if you're still around :-)
<magopian> reynir: it's fine, I believe my question is answered already, but thanks a lot for offering your help!
ShalokShalom_ has joined #reasonml
ShalokShalom has quit [Ping timeout: 240 seconds]
andreas__ has joined #reasonml
ShalokShalom_ has quit [Ping timeout: 240 seconds]
xkapastel has joined #reasonml
andreas__ has quit [Quit: Connection closed for inactivity]
<chenglou> @magopian hello!
<chenglou> that mutation is needed (and a single layer `mutable` field won't do). You're right. The instance vars section is mostly an interop mechanism to regular reactjs patterns