1.0.0-alpha.2 • Published 6 years ago

@koreez/observex v1.0.0-alpha.2

Weekly downloads
-
License
MIT
Repository
github
Last release
6 years ago

observex

GitHub license Build Status npm version styled with prettier

Observex plugin!

Key features:

Blazing fast Low memory usage Easy to use API

Getting Started

First you want to get a fresh copy. You can get it from this repo or from npm, ain't that handy. npm

npm install @koreez/observex --save

Usage

import { observable, reaction } from "@koreez/observex";

const user = observable({
    name: "John",
    age: 27
});

reaction(user, ["age"], (newAge, propertyName) => {
    console.log("age update", newAge, propertyName);
});

user.age = 28; // 'age update' 28, 'age'

License

MIT