Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

连续调用数组的push,侦听器的第二个参数不符合预期 #12

Open
nkcjs opened this issue Oct 23, 2017 · 0 comments
Open

Comments

@nkcjs
Copy link

nkcjs commented Oct 23, 2017

const obj = {
    a: 1,
    items: []
  }

observe(obj, function (name, value) {
    console.log(name + "  " + value) 
})

obj.items.push(1)
obj.items.push(2)
obj.items.push(3)

第一次push
image

第二次push
image

第三次push
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant