magic-status

v1.0.0
a status object with getter/setter properties

magic-status Build Status

an automatic status object. First you define properties with default values, add a callback function, give a wait time, returns a status object, setting the properties will now result in the cb being called after wait time, only with the updated properties.

todo: make option to always send all

        status = ms({
            asd: 5,
            hoi: 'daag',
            foo: 'bar',
            bar: 'baz'
        }, console.log.bind( console, 'update :' ), 3000 );

status.hoi; // 5
status.hoi = 3;

// update: { hoi: 3 }```

Metadata

  • ISC
  • Whatever
  • =
  • released 11/9/2015

Downloads

Maintainers