{"action":"opened","issue":{"url":"https://api.github.com/repos/muut/riotjs/issues/338","labels_url":"https://api.github.com/repos/muut/riotjs/issues/338/labels{/name}","comments_url":"https://api.github.com/repos/muut/riotjs/issues/338/comments","events_url":"https://api.github.com/repos/muut/riotjs/issues/338/events","html_url":"https://github.com/muut/riotjs/issues/338","id":57211250,"number":338,"title":".on('update') bug","user":{"login":"e-jigsaw","id":557961,"avatar_url":"https://avatars.githubusercontent.com/u/557961?v=3","gravatar_id":"","url":"https://api.github.com/users/e-jigsaw","html_url":"https://github.com/e-jigsaw","followers_url":"https://api.github.com/users/e-jigsaw/followers","following_url":"https://api.github.com/users/e-jigsaw/following{/other_user}","gists_url":"https://api.github.com/users/e-jigsaw/gists{/gist_id}","starred_url":"https://api.github.com/users/e-jigsaw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/e-jigsaw/subscriptions","organizations_url":"https://api.github.com/users/e-jigsaw/orgs","repos_url":"https://api.github.com/users/e-jigsaw/repos","events_url":"https://api.github.com/users/e-jigsaw/events{/privacy}","received_events_url":"https://api.github.com/users/e-jigsaw/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-02-10T17:59:29Z","updated_at":"2015-02-10T17:59:29Z","closed_at":null,"body":"Sample code:\r\n\r\n`parent.tag`:\r\n\r\n```\r\n<parent>\r\n  <child1 data='{ data }'></child1>\r\n  <child2 update='{ updateChild1 }'></child2>\r\n\r\n  this.data = 'hoge'\r\n  this.updateChild1 = function(event) {\r\n    this.update({\r\n      data: 'fuga'\r\n    })\r\n  }.bind(this)\r\n</parent>\r\n```\r\n\r\n`child1.tag`:\r\n\r\n```\r\n<child1>\r\n  <p>child 1</p>\r\n\r\n  this.on('update', function(event){\r\n    console.log(opts.data)\r\n  })\r\n</child1>\r\n```\r\n\r\n`child2.tag`:\r\n\r\n```\r\n<child2>\r\n  <button onclick='{ onclick }'>test</button>\r\n  this.onclick = function(event) {\r\n    console.log('click')\r\n    opts.update(event)\r\n  }\r\n</child2>\r\n```\r\n\r\nThis code is show `opts.data` in `child1` each click in `child2` button.\r\n\r\nin riot@2.0.7:\r\n\r\n```\r\nhoge\r\nhoge\r\nclick\r\nfuga\r\n```\r\n\r\nin riot@2.0.8:\r\n\r\n```\r\nhoge\r\nhoge\r\nclick\r\nhoge\r\nclick\r\nfuga\r\n```\r\n\r\n`.on('update')` is delayed. Does this behavior would be a bug?\r\n\r\nThanks"}}