You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sergey Sharov edited this page Aug 20, 2016
·
3 revisions
MobX supports ES5, ES6, and Typescript. Let's compare the README example in each language to understand how to use MobX in your language ecosystem of choice.
TypeScript or ES6 + Instance Fields + Decorators
This is a great example of how using the latest JavaScript features help reduce boilerplate and increase code readability.
import {observable} from 'mobx';
class Todo {
id = Math.random();
@observable title = "";
@observable finished = false;
}