Replies: 1 comment 2 replies
-
This is all documented. See the action docs, the section about writing
async actions.
…On Fri, 8 Jan 2021, 18:45 Merynek, ***@***.***> wrote:
Hello,
I have problem with mobx action with async method depend on changes.
I tried lot of stuff for fix this but without success.
@action
private async processMethod(arg1: number, arg2: number) {
this.bigStore.set1(arg1); // this line change some observable properties => need rerender
this.bigStore.set2(arg2); // this line change some observable properties => need rerender
// in this time rerender is called first time (OK)
await this.processBigChange(); // this line is depend lines above and change lot of observable properties
// in this time rerender is called second time (FAIL => need just one rerender)
}
Have you ever had this issue?
*Version*
"mobx": "^5.15.7",
"mobx-react": "^6.3.1"
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#2704>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAN4NBAYGA2WO5XTLJLEWZDSY5HFTANCNFSM4V22GFHQ>
.
|
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I have problem with mobx action with async method depend on changes.
I tried lot of stuff for fix this but without success.
Have you ever had this issue?
Version
"mobx": "^5.15.7",
"mobx-react": "^6.3.1"
Beta Was this translation helpful? Give feedback.
All reactions