{"action":"created","issue":{"url":"https://api.github.com/repos/littlebits/stream-sift/issues/12","labels_url":"https://api.github.com/repos/littlebits/stream-sift/issues/12/labels{/name}","comments_url":"https://api.github.com/repos/littlebits/stream-sift/issues/12/comments","events_url":"https://api.github.com/repos/littlebits/stream-sift/issues/12/events","html_url":"https://github.com/littlebits/stream-sift/issues/12","id":53523454,"number":12,"title":"BANG operator? $fn mashups?","user":{"login":"jasonkuhrt","id":284476,"avatar_url":"https://avatars.githubusercontent.com/u/284476?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkuhrt","html_url":"https://github.com/jasonkuhrt","followers_url":"https://api.github.com/users/jasonkuhrt/followers","following_url":"https://api.github.com/users/jasonkuhrt/following{/other_user}","gists_url":"https://api.github.com/users/jasonkuhrt/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkuhrt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkuhrt/subscriptions","organizations_url":"https://api.github.com/users/jasonkuhrt/orgs","repos_url":"https://api.github.com/users/jasonkuhrt/repos","events_url":"https://api.github.com/users/jasonkuhrt/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkuhrt/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/littlebits/stream-sift/labels/feature","name":"feature","color":"207de5"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-01-06T15:06:47Z","updated_at":"2015-01-06T16:15:54Z","closed_at":null,"body":"Could we support something like this?\r\n\r\n\r\n```\r\n{ fruit: { '!$in': ['lemon'] } }\r\n```\r\n\r\nThe current equivalent would be:\r\n\r\n```\r\n{ fruit: { '$nin': ['lemon'] } }\r\n```\r\n\r\nThe maybe \"advantage\" of a separate `bang` operator is that it could be used at will without the requirement of `n*` function variants. How useful is this? Seems dubious. Plus we actually introduce syntax that now requires keys to be wrapped in quotes. This introduces inconsistency, reduces readability, harder to type; big losses!\r\n\r\nAnother thought is instead of `!` allowing combinations of `$fn` like so:\r\n\r\n```\r\n{ fruit: { $not$in: ['lemon'] } }\r\n```\r\n\r\nThis avoids the quotes problem but how scalable is such a system? Beyond this use-case what would composite `$` mean? This seems better than the above idea, but still dubious."},"comment":{"url":"https://api.github.com/repos/littlebits/stream-sift/issues/comments/68887024","html_url":"https://github.com/littlebits/stream-sift/issues/12#issuecomment-68887024","issue_url":"https://api.github.com/repos/littlebits/stream-sift/issues/12","id":68887024,"user":{"login":"jasonkuhrt","id":284476,"avatar_url":"https://avatars.githubusercontent.com/u/284476?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkuhrt","html_url":"https://github.com/jasonkuhrt","followers_url":"https://api.github.com/users/jasonkuhrt/followers","following_url":"https://api.github.com/users/jasonkuhrt/following{/other_user}","gists_url":"https://api.github.com/users/jasonkuhrt/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkuhrt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkuhrt/subscriptions","organizations_url":"https://api.github.com/users/jasonkuhrt/orgs","repos_url":"https://api.github.com/users/jasonkuhrt/repos","events_url":"https://api.github.com/users/jasonkuhrt/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkuhrt/received_events","type":"User","site_admin":false},"created_at":"2015-01-06T16:15:54Z","updated_at":"2015-01-06T16:15:54Z","body":"Also to be fair its not practical to provide `n*` prefix versions of each `$fn` just because it gets silly for already-abbreviated things:\r\n\r\n```\r\n$ncgte\r\n```\r\n\r\nSo the idea of being able to do either:\r\n\r\n```\r\n$not: { $cgte: ... }\r\n\r\n# or \r\n$not$cgte\r\n```"}}