-
Seems like updating an observable inside a rendering function will not behave nicely:
Is it possible that this is by design to prevent infinite rendering? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
IDK about details of current implementation, but in general changing observables within an autorun\reaction is not recommended by the docs: |
Beta Was this translation helpful? Give feedback.
-
Consider using a simple setter without any autorun / reactions:
|
Beta Was this translation helpful? Give feedback.
-
Possibly same as #2346, not entirely sure |
Beta Was this translation helpful? Give feedback.
IDK about details of current implementation, but in general changing observables within an autorun\reaction is not recommended by the docs:
https://mobx.js.org/reactions.html#use-reactions-sparingly