Skip to content

Instantly share code, notes, and snippets.


jkh jiangkunhe

  • 58
  • Beijing
Block or report user

Report or block jiangkunhe

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
jiangkunhe / v1.js
Created Apr 10, 2019
vue observe demo
View v1.js
const data = {}
let a = 1
let dep = []
let Target = null
Object.defineProperty(data, 'a', {
set: function(val) {
a = val
dep.forEach(fn => fn())
You can’t perform that action at this time.