{"action":"created","issue":{"url":"https://api.github.com/repos/ryansolid/solid/issues/5","repository_url":"https://api.github.com/repos/ryansolid/solid","labels_url":"https://api.github.com/repos/ryansolid/solid/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/ryansolid/solid/issues/5/comments","events_url":"https://api.github.com/repos/ryansolid/solid/issues/5/events","html_url":"https://github.com/ryansolid/solid/issues/5","id":367622979,"node_id":"MDU6SXNzdWUzNjc2MjI5Nzk=","number":5,"title":"reversing order of operator?","user":{"login":"trusktr","id":297678,"node_id":"MDQ6VXNlcjI5NzY3OA==","avatar_url":"https://avatars3.githubusercontent.com/u/297678?v=4","gravatar_id":"","url":"https://api.github.com/users/trusktr","html_url":"https://github.com/trusktr","followers_url":"https://api.github.com/users/trusktr/followers","following_url":"https://api.github.com/users/trusktr/following{/other_user}","gists_url":"https://api.github.com/users/trusktr/gists{/gist_id}","starred_url":"https://api.github.com/users/trusktr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trusktr/subscriptions","organizations_url":"https://api.github.com/users/trusktr/orgs","repos_url":"https://api.github.com/users/trusktr/repos","events_url":"https://api.github.com/users/trusktr/events{/privacy}","received_events_url":"https://api.github.com/users/trusktr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-10-08T02:44:10Z","updated_at":"2018-10-08T21:45:05Z","closed_at":null,"author_association":"NONE","body":"I see the TodoMVC example has some code like\r\n\r\n```jsx\r\n{when(() => <TodoFooter {...props} />)(() => props.state.todos.length > 0)}\r\n```\r\n\r\nbut it seems like it would be easier to read if it were \r\n\r\n```js\r\n{when(() => props.state.todos.length > 0)(() => <TodoFooter {...props} />)}\r\n```\r\n\r\nIs that possible to make `when` be that way without performance impact?\r\n\r\nSimilarly with `each`, I feel like it'd be nicer to read if it were\r\n\r\n```jsx\r\n      each(() => filterList(state.todos))(todo =>\r\n        <TodoItem {...props} todo={todo} />\r\n      )\r\n```"},"comment":{"url":"https://api.github.com/repos/ryansolid/solid/issues/comments/427989391","html_url":"https://github.com/ryansolid/solid/issues/5#issuecomment-427989391","issue_url":"https://api.github.com/repos/ryansolid/solid/issues/5","id":427989391,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNzk4OTM5MQ==","user":{"login":"ryansolid","id":2768267,"node_id":"MDQ6VXNlcjI3NjgyNjc=","avatar_url":"https://avatars0.githubusercontent.com/u/2768267?v=4","gravatar_id":"","url":"https://api.github.com/users/ryansolid","html_url":"https://github.com/ryansolid","followers_url":"https://api.github.com/users/ryansolid/followers","following_url":"https://api.github.com/users/ryansolid/following{/other_user}","gists_url":"https://api.github.com/users/ryansolid/gists{/gist_id}","starred_url":"https://api.github.com/users/ryansolid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ryansolid/subscriptions","organizations_url":"https://api.github.com/users/ryansolid/orgs","repos_url":"https://api.github.com/users/ryansolid/repos","events_url":"https://api.github.com/users/ryansolid/events{/privacy}","received_events_url":"https://api.github.com/users/ryansolid/received_events","type":"User","site_admin":false},"created_at":"2018-10-08T21:45:05Z","updated_at":"2018-10-08T21:45:05Z","author_association":"OWNER","body":"I didn't finish my thought here. So to your example you can use pipe.\r\n```jsx\r\npipe(() => props.state.todos.length > 0, when(() => <TodoFooter {...props} />))\r\n```\r\nThe operator naming perhaps needs work.. When suggests condition and Each suggests the iterated, when in fact both are just the mapping function. \r\n\r\nFor single operators I tend to not use pipe since the all is flat enough. \r\n"}}
{"actor":{"display_login":"ryansolid"}}