{"action":"created","issue":{"url":"https://api.github.com/repos/ReactiveX/RxJS/issues/322","labels_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/322/labels{/name}","comments_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/322/comments","events_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/322/events","html_url":"https://github.com/ReactiveX/RxJS/pull/322","id":106835993,"number":322,"title":"feat(operator): add single operator","user":{"login":"kwonoj","id":1210596,"avatar_url":"https://avatars.githubusercontent.com/u/1210596?v=3","gravatar_id":"","url":"https://api.github.com/users/kwonoj","html_url":"https://github.com/kwonoj","followers_url":"https://api.github.com/users/kwonoj/followers","following_url":"https://api.github.com/users/kwonoj/following{/other_user}","gists_url":"https://api.github.com/users/kwonoj/gists{/gist_id}","starred_url":"https://api.github.com/users/kwonoj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kwonoj/subscriptions","organizations_url":"https://api.github.com/users/kwonoj/orgs","repos_url":"https://api.github.com/users/kwonoj/repos","events_url":"https://api.github.com/users/kwonoj/events{/privacy}","received_events_url":"https://api.github.com/users/kwonoj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-16T18:41:52Z","updated_at":"2015-09-17T18:11:32Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ReactiveX/RxJS/pulls/322","html_url":"https://github.com/ReactiveX/RxJS/pull/322","diff_url":"https://github.com/ReactiveX/RxJS/pull/322.diff","patch_url":"https://github.com/ReactiveX/RxJS/pull/322.patch"},"body":"Continue effort to add operator exists in current RxJS."},"comment":{"url":"https://api.github.com/repos/ReactiveX/RxJS/issues/comments/141170183","html_url":"https://github.com/ReactiveX/RxJS/pull/322#issuecomment-141170183","issue_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/322","id":141170183,"user":{"login":"blesh","id":1540597,"avatar_url":"https://avatars.githubusercontent.com/u/1540597?v=3","gravatar_id":"","url":"https://api.github.com/users/blesh","html_url":"https://github.com/blesh","followers_url":"https://api.github.com/users/blesh/followers","following_url":"https://api.github.com/users/blesh/following{/other_user}","gists_url":"https://api.github.com/users/blesh/gists{/gist_id}","starred_url":"https://api.github.com/users/blesh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/blesh/subscriptions","organizations_url":"https://api.github.com/users/blesh/orgs","repos_url":"https://api.github.com/users/blesh/repos","events_url":"https://api.github.com/users/blesh/events{/privacy}","received_events_url":"https://api.github.com/users/blesh/received_events","type":"User","site_admin":false},"created_at":"2015-09-17T18:11:32Z","updated_at":"2015-09-17T18:11:32Z","body":"Actually, now that I'm digging into this operator I rarely use and researching the C# semantic it was born from, it looks like current RxJS and this impl are doing something weird with it.\r\n\r\n[Enumerable.Single()](https://msdn.microsoft.com/en-us/library/vstudio/bb155325(v=vs.100).aspx) asserts that there is a single element in the enumerable.\r\n\r\nlikewise [Observable.Single()](https://msdn.microsoft.com/en-us/library/Hh229425(v=VS.103).aspx) does the same.\r\n\r\nThe current RxJS version is like an alternate version of `first()`, to me.\r\n\r\nWe could actually benefit from a `single()` that asserted a single item in an Observable, because it could return a `ScalarObservable`, which has optimizations in parts of our code. Also it would provide functionality that `first()` did not.\r\n\r\n@mattpodwysocki, what are your thoughts?"}}