{"action":"created","issue":{"url":"https://api.github.com/repos/ReactiveX/rxjs/issues/1888","repository_url":"https://api.github.com/repos/ReactiveX/rxjs","labels_url":"https://api.github.com/repos/ReactiveX/rxjs/issues/1888/labels{/name}","comments_url":"https://api.github.com/repos/ReactiveX/rxjs/issues/1888/comments","events_url":"https://api.github.com/repos/ReactiveX/rxjs/issues/1888/events","html_url":"https://github.com/ReactiveX/rxjs/issues/1888","id":172297392,"number":1888,"title":"Rename main entry /Rx.js to /index.js","user":{"login":"jayphelps","id":762949,"avatar_url":"https://avatars.githubusercontent.com/u/762949?v=3","gravatar_id":"","url":"https://api.github.com/users/jayphelps","html_url":"https://github.com/jayphelps","followers_url":"https://api.github.com/users/jayphelps/followers","following_url":"https://api.github.com/users/jayphelps/following{/other_user}","gists_url":"https://api.github.com/users/jayphelps/gists{/gist_id}","starred_url":"https://api.github.com/users/jayphelps/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jayphelps/subscriptions","organizations_url":"https://api.github.com/users/jayphelps/orgs","repos_url":"https://api.github.com/users/jayphelps/repos","events_url":"https://api.github.com/users/jayphelps/events{/privacy}","received_events_url":"https://api.github.com/users/jayphelps/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2016-08-21T00:09:12Z","updated_at":"2016-08-21T02:18:59Z","closed_at":null,"body":"Many in the community have started importing all  of RxJS by directing referencing the entry file `\"rxjs/Rx\"`\r\n\r\n```js\r\nimport Rx from 'rxjs/Rx';\r\n```\r\n\r\nInstead of just importing it from the module root `\"rxjs\"` and letting their resolver decide where to find it (usually via package.json `main` field)\r\n\r\n```js\r\nimport Rx from 'rxjs';\r\n```\r\n\r\nThis is weird to me and is I've noticed is confusing to some people who believe there is a difference between the two other than the first one is more brittle, relying on the the exact name of the entry file.\r\n\r\nIs there a particular reason we named it `Rx.js` instead of the usual `index.js`? I realize changing this now will certainly break people who rely on this, so if anyone is worried I'm not opposed to a single deprecation release with a `console.warn()`.\r\n\r\nAlso--do any TypeScript pros know if there is any between the two from a typing perspective?"},"comment":{"url":"https://api.github.com/repos/ReactiveX/rxjs/issues/comments/241234958","html_url":"https://github.com/ReactiveX/rxjs/issues/1888#issuecomment-241234958","issue_url":"https://api.github.com/repos/ReactiveX/rxjs/issues/1888","id":241234958,"user":{"login":"Meligy","id":171637,"avatar_url":"https://avatars.githubusercontent.com/u/171637?v=3","gravatar_id":"","url":"https://api.github.com/users/Meligy","html_url":"https://github.com/Meligy","followers_url":"https://api.github.com/users/Meligy/followers","following_url":"https://api.github.com/users/Meligy/following{/other_user}","gists_url":"https://api.github.com/users/Meligy/gists{/gist_id}","starred_url":"https://api.github.com/users/Meligy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Meligy/subscriptions","organizations_url":"https://api.github.com/users/Meligy/orgs","repos_url":"https://api.github.com/users/Meligy/repos","events_url":"https://api.github.com/users/Meligy/events{/privacy}","received_events_url":"https://api.github.com/users/Meligy/received_events","type":"User","site_admin":false},"created_at":"2016-08-21T02:18:59Z","updated_at":"2016-08-21T02:18:59Z","body":"For Babel, the normal scenario seems to work well:\r\n\r\n```javascript\r\nimport { Observable } from 'rxjs/Rx';\r\n\r\nObservable\r\n    .from([1,2,3])\r\n    .map(function(n) { return  \"Number \" + n; })\r\n    .subscribe(console.log);\r\n```\r\n\r\nSo, this bit at least is good and makes sense.\r\n\r\nI think I got it confused because in TypeScript it doesn't work. Probably a typings issue. I have had it only with beta 6 though in Angular apps so I'll test this again with beta 12.\r\n\r\nOne thing to mention about the above example though is that it's of course not tree-shakable."}}
{"actor":{"display_login":"Meligy"}}