{"action":"created","issue":{"url":"https://api.github.com/repos/slamdata/purescript-halogen/issues/81","labels_url":"https://api.github.com/repos/slamdata/purescript-halogen/issues/81/labels{/name}","comments_url":"https://api.github.com/repos/slamdata/purescript-halogen/issues/81/comments","events_url":"https://api.github.com/repos/slamdata/purescript-halogen/issues/81/events","html_url":"https://github.com/slamdata/purescript-halogen/pull/81","id":69055000,"number":81,"title":"Fix #65, version inputs to widget components","user":{"login":"paf31","id":630306,"avatar_url":"https://avatars.githubusercontent.com/u/630306?v=3","gravatar_id":"","url":"https://api.github.com/users/paf31","html_url":"https://github.com/paf31","followers_url":"https://api.github.com/users/paf31/followers","following_url":"https://api.github.com/users/paf31/following{/other_user}","gists_url":"https://api.github.com/users/paf31/gists{/gist_id}","starred_url":"https://api.github.com/users/paf31/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paf31/subscriptions","organizations_url":"https://api.github.com/users/paf31/orgs","repos_url":"https://api.github.com/users/paf31/repos","events_url":"https://api.github.com/users/paf31/events{/privacy}","received_events_url":"https://api.github.com/users/paf31/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-04-17T03:30:49Z","updated_at":"2015-04-17T04:03:25Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/slamdata/purescript-halogen/pulls/81","html_url":"https://github.com/slamdata/purescript-halogen/pull/81","diff_url":"https://github.com/slamdata/purescript-halogen/pull/81.diff","patch_url":"https://github.com/slamdata/purescript-halogen/pull/81.patch"},"body":"@jdegoes @garyb @puffnfresh Could you please review?\r\n\r\nAfter several attempts, this is the only thing I could come up with which works. The idea is to version each input to the component by pairing the inputs with a counter. Inside the widget, if the version has not been bumped, we don't invoke the `update` action during the diff.\r\n\r\nI'm not exactly proud of this fix, but I think it's about as good as it's going to get without an effectful signal function (unless there are other ideas)...\r\n\r\nThanks."},"comment":{"url":"https://api.github.com/repos/slamdata/purescript-halogen/issues/comments/93888466","html_url":"https://github.com/slamdata/purescript-halogen/pull/81#issuecomment-93888466","issue_url":"https://api.github.com/repos/slamdata/purescript-halogen/issues/81","id":93888466,"user":{"login":"paf31","id":630306,"avatar_url":"https://avatars.githubusercontent.com/u/630306?v=3","gravatar_id":"","url":"https://api.github.com/users/paf31","html_url":"https://github.com/paf31","followers_url":"https://api.github.com/users/paf31/followers","following_url":"https://api.github.com/users/paf31/following{/other_user}","gists_url":"https://api.github.com/users/paf31/gists{/gist_id}","starred_url":"https://api.github.com/users/paf31/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paf31/subscriptions","organizations_url":"https://api.github.com/users/paf31/orgs","repos_url":"https://api.github.com/users/paf31/repos","events_url":"https://api.github.com/users/paf31/events{/privacy}","received_events_url":"https://api.github.com/users/paf31/received_events","type":"User","site_admin":false},"created_at":"2015-04-17T04:03:25Z","updated_at":"2015-04-17T04:03:25Z","body":"After my short testing, it seems good to go, but the only example I have right now is my mini Ace example.\r\n\r\nThe issue isn't with events on the output side. Those _do_ behave like pure components. The problem is when we want events to behave like inputs, but all we have is a function `input -> Eff _ _`. We can partially apply this and embed the `Eff` action into the `update` part of the widget, but a pure signal function captures the same `input` even when there is nothing to update. This change basically makes the update function only fire the first time it is called after the last input."}}