Skip to content

Instantly share code, notes, and snippets.

A proxy version of mobx: dob

Why use proxy to achieve mobx? Because mobx is very good, but because of Object.defineProperty restrictions, no way to write very comfortable.

So dob was born, I only list the changes after using dob, as well as the experience of store manager framework practice summary.

1 Introduction

dob not only overrides mobx using proxy, but also comes with dependency injection store management.

@geoffmiller
geoffmiller / mobx-recompose.jsx
Last active December 11, 2018 22:20
Mobx with Recompose structure
const { compose, mapProps, withHandlers, lifecycle } = Recompose;
const { observable, action } = mobx;
const { inject, observer, Provider } = mobxReact;
const { PropTypes } = React;
// store
// ============================
const counterStore = observable({
// for primitive values, wrap the value inside a observable,
// or wrap it in an plain js object
@btroncone
btroncone / ngrxintro.md
Last active February 9, 2024 15:37
A Comprehensive Introduction to @ngrx/store - Companion to Egghead.io Series

Comprehensive Introduction to @ngrx/store

By: @BTroncone

Also check out my lesson @ngrx/store in 10 minutes on egghead.io!

Update: Non-middleware examples have been updated to ngrx/store v2. More coming soon!

Table of Contents