Feature: Support Mobx strict mode
See original GitHub issueHi! When I enable strict mode via configure({ enforceActions: true });
, it seems to cause mobx to throw an Error from within this library. Specifically, I think it comes from Document._onSnapshot
when the transaction
updates _fetching
via this line:
this._fetching.set(false);
Is there anything I can do in my usage of firestorter to allow me to enforce actions and also not run into this issue? I am happy to contribute, so if you point out a place in the code that you think we could update something, let me know and I’ll submit a PR.
Cheers!
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:7 (4 by maintainers)
Top Results From Across the Web
Configuration · MobX
"always" (default): MobX expects to run only in environments with Proxy support and it will error if such an environment is not available....
Read more >MobX: Since strict-mode is enabled, changing (observed ...
reactjs - MobX: Since strict-mode is enabled, changing (observed) observable values without using an action is not allowed - Stack Overflow. ...
Read more >Strict mode error shows up only in development build #2430
Uncaught Error: [mobx] Since strict-mode is enabled, changing observed observable values outside actions is not allowed.
Read more >Enforcing the use of actions - MobX Quick Start Guide [Book]
In fact, this can be made mandatory by configuring MobX to always enforce this policy, also called the strict mode. The configure() function...
Read more >7 tips for using MobX - Huiseoul Engineering
So MobX provides a strict mode where you can only change your data inside of functions marked as actions can change observable values....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Not yet. I will pick this up in a couple weeks after my vacation. It’s basically the next thing on my prio list 👍
Op wo 24 okt. 2018 19:23 schreef Michael Zipperle <notifications@github.com
Hi, MobX strict mode is now supported in v1.1.0. Let me know whether this solves the problem for you. cheers