observer-properties
v1.0.0
Published
watch object propery change
Downloads
1
Readme
INSTALL
npm i -S ObserverProperties
USAGE
const Observe = require('observer-properties')
const a = { name: 'zhou', loves: { music: true } }
Observe(a, (oldValue, newValue) => {
console.log(oldValue, newValue)
})
a.name = 'chao' // zhou chao
a.loves.music = false // true false