Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debugger logging numerous action type "┃ add" causes crash #24

Open
justingosan opened this issue Jun 15, 2017 · 2 comments
Open

Debugger logging numerous action type "┃ add" causes crash #24

justingosan opened this issue Jun 15, 2017 · 2 comments

Comments

@justingosan
Copy link

justingosan commented Jun 15, 2017

Not sure if this is an issue in mobx, in RN or just in my code but here goes:

Basically I have a huge array of objects (with multiple properties) that I made observable in my Store. I do a single asynchronous fetch call which basically populates the variable.

When I plug mobx-remotedev in, the inspector logs multiple (seemingly infinite) "┃ add" action types for each property in each object of the array. This causes the remote debugger to hang and if i plug locally to "react-native-debugger", the app also hangs.

Is this normal behavior for mobx? If so how do I prevent the debugger from crashing?
Thanks!

@justingosan justingosan changed the title Debugger is logging "┃ add" Debugger logging numerous action type "┃ add" causes crash Jun 15, 2017
@zalmoxisus
Copy link
Owner

You can set onlyActions parameter to true so only mobx actions will be logged. The reason why the debugger is logging everything is that MobX isn't in strict mode. But that's odd you have so many add there.

@kubk
Copy link

kubk commented Nov 11, 2019

I encountered the same problem. Enabling MobX's strict mode fixed the problem. Pretty sure this issue can be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants