Dob ·

Dob is a tool for monitoring object changes. Using Proxy.
Examples
There are some demo on fiddle. Here's the simplest:
import { observable, observe } from "dob"
const obj = observable({ a: 1 })
observe(() => {
console.log("obj.a has changed to", obj.a)
})
obj.a = 2
You can enjoy the benefits of proxy, for example obj.a = { b: 5 }
is effective.
Installation
Dob is available as the dob
package on npm. It is also available on a CDN.
npm i dob
Apis
You can read quick start first, then read them:
Combination
Combining dob-react
Quick start
Here is a basic demo, and here is a demo with fractal.
Combining dependency-inject
Here is a basic demo, and here is a demo with fractal and dependency-inject.
Combining react-redux
Here is a basic demo
You can clone this project, and run npm start
to see redux todoMVC demo.
Inspired