Reaction is not getting fired correctly #2561
Answered
by
mweststrate
smriti-chawla
asked this question in
Q&A
Replies: 2 comments 6 replies
-
Try |
Beta Was this translation helpful? Give feedback.
2 replies
-
See https://mobx.js.org/understanding-reactivity.html, mobx only tracks
what you are actually reading; in your example you are reading the keys and
values of the map, but not any attributes of the events itself, so those
won't be tracked.
…On Mon, Oct 26, 2020 at 6:09 PM Daniel K. ***@***.***> wrote:
Best if you can setup reproduction with eg. CodeSandbox.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#2561 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAN4NBHVEOZR3Z4Z6N4QPKLSMW3N5ANCNFSM4S7QPK6Q>
.
|
Beta Was this translation helpful? Give feedback.
4 replies
Answer selected by
smriti-chawla
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
activeImpact is an observable like below
the reaction is getting fired whenever there is a change in the length of this.activeImpact.events.
However, I want to fire this whenever there is any change in this.activeImpact.events whether it's a specific property to it.
for eg if I do something like
then in that case the reaction is working for change in property id and name .
however, there are so many properties in this I cannot write then like this to observe the change
Beta Was this translation helpful? Give feedback.
All reactions