Mobx.dart: Q: debug reason of rebuild

Created on 1 Feb 2020  路  7Comments  路  Source: mobxjs/mobx.dart

is possible we detect why an observer is rebuild ?

i have too many nested Observer widget, i want debug why my parent Observer is rebuilt ( what variable is changed ? ), how can i debug it ?

thanks

Most helpful comment

@DJafari we don't have logging of the reactions yet. It's a feature I'm going to start working on soon. We call this "spying" in the MobX parlance.

All 7 comments

A good resource I use is to name the observer.
Observer (name: 'debug name', build: ...)

@jacobaraujo7 but i don't see any output in logs

@DJafari we don't have logging of the reactions yet. It's a feature I'm going to start working on soon. We call this "spying" in the MobX parlance.

@pavanpodila any update from this feature ?

The spy feature is complete and waiting to be merged. Some build failure going on Github Action, which I am not able to resolve :-(. If you want to give it a try, you can take a look in this PR: #451

The spy feature is now merged into master, but not yet part of an official release. The docs are still pending and I'll put up a new version once that's ready :-)

I'm closing this issue and creating a new one for the docs and new version

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jiyarong picture jiyarong  路  4Comments

viktorszekeress picture viktorszekeress  路  4Comments

rrousselGit picture rrousselGit  路  6Comments

dukaric1991 picture dukaric1991  路  5Comments

Tywholland picture Tywholland  路  3Comments