{"action":"closed","issue":{"url":"https://api.github.com/repos/reflex-frp/reflex/issues/213","repository_url":"https://api.github.com/repos/reflex-frp/reflex","labels_url":"https://api.github.com/repos/reflex-frp/reflex/issues/213/labels{/name}","comments_url":"https://api.github.com/repos/reflex-frp/reflex/issues/213/comments","events_url":"https://api.github.com/repos/reflex-frp/reflex/issues/213/events","html_url":"https://github.com/reflex-frp/reflex/issues/213","id":346010042,"node_id":"MDU6SXNzdWUzNDYwMTAwNDI=","number":213,"title":"Proposal: pushDyn primitive","user":{"login":"Saulzar","id":1128677,"node_id":"MDQ6VXNlcjExMjg2Nzc=","avatar_url":"https://avatars0.githubusercontent.com/u/1128677?v=4","gravatar_id":"","url":"https://api.github.com/users/Saulzar","html_url":"https://github.com/Saulzar","followers_url":"https://api.github.com/users/Saulzar/followers","following_url":"https://api.github.com/users/Saulzar/following{/other_user}","gists_url":"https://api.github.com/users/Saulzar/gists{/gist_id}","starred_url":"https://api.github.com/users/Saulzar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Saulzar/subscriptions","organizations_url":"https://api.github.com/users/Saulzar/orgs","repos_url":"https://api.github.com/users/Saulzar/repos","events_url":"https://api.github.com/users/Saulzar/events{/privacy}","received_events_url":"https://api.github.com/users/Saulzar/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2018-07-31T02:17:08Z","updated_at":"2018-08-19T13:05:11Z","closed_at":"2018-08-19T13:05:11Z","author_association":"COLLABORATOR","body":"`pushDyn :: MonadHold t m => (a -> PushM t b) -> Dynamic t a -> m (Dynamic t b)`\r\n\r\nI believe this would eliminate quite a few of the awkward situations where you would prefer to have a function with `Dynamic` input, but need the initial value. \r\n\r\nSo currently you have two solutions (ignoring use of `sample` which is discouraged for good reason!)\r\n1) Use `(a, Event t a)`\r\n2) Use `postBuild` to sample the `Dynamic` later\r\n\r\nI believe this eliminates the need for most of these awkward situations, would enable `factorDyn` without `sample` as well as simplify a lot of use of `postBuild`. It seems safe to me - implemented by a queue in Spider which gets processed similarly to the way `hold` is.\r\n\r\nHappy to have a go at it when I get a few minutes too, just curious what people think first. Is there any reason it wouldn't work/be unsafe? @ryantrinkle?\r\n"}}
{"actor":{"display_login":"Saulzar"}}