What is MobX toJS?

Usage: toJS(value) Recursively converts an observable object to a JavaScript object . Supports observable arrays, objects, Maps and primitives. It does NOT recurse into non-observables, these are left as they are, even if they contain observables.

Read more

How do you compute in MobX?

Computed values can be created by annotating JavaScript getters with computed . Use makeObservable to declare a getter as computed. If you instead want all getters to be automatically declared as computed , you can use either makeAutoObservable , observable or extendObservable .

Read more