{"action":"created","issue":{"url":"https://api.github.com/repos/benmosher/eslint-plugin-import/issues/889","repository_url":"https://api.github.com/repos/benmosher/eslint-plugin-import","labels_url":"https://api.github.com/repos/benmosher/eslint-plugin-import/issues/889/labels{/name}","comments_url":"https://api.github.com/repos/benmosher/eslint-plugin-import/issues/889/comments","events_url":"https://api.github.com/repos/benmosher/eslint-plugin-import/issues/889/events","html_url":"https://github.com/benmosher/eslint-plugin-import/issues/889","id":241483894,"number":889,"title":"Rule to prohibit default exports","user":{"login":"isiahmeadows","id":4483844,"avatar_url":"https://avatars1.githubusercontent.com/u/4483844?v=4","gravatar_id":"","url":"https://api.github.com/users/isiahmeadows","html_url":"https://github.com/isiahmeadows","followers_url":"https://api.github.com/users/isiahmeadows/followers","following_url":"https://api.github.com/users/isiahmeadows/following{/other_user}","gists_url":"https://api.github.com/users/isiahmeadows/gists{/gist_id}","starred_url":"https://api.github.com/users/isiahmeadows/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/isiahmeadows/subscriptions","organizations_url":"https://api.github.com/users/isiahmeadows/orgs","repos_url":"https://api.github.com/users/isiahmeadows/repos","events_url":"https://api.github.com/users/isiahmeadows/events{/privacy}","received_events_url":"https://api.github.com/users/isiahmeadows/received_events","type":"User","site_admin":false},"labels":[{"id":314574677,"url":"https://api.github.com/repos/benmosher/eslint-plugin-import/labels/accepted","name":"accepted","color":"bfe5bf","default":false},{"id":187330416,"url":"https://api.github.com/repos/benmosher/eslint-plugin-import/labels/help/PR%20wanted","name":"help/PR wanted","color":"159818","default":false},{"id":308703015,"url":"https://api.github.com/repos/benmosher/eslint-plugin-import/labels/rule%20proposal","name":"rule proposal","color":"fef2c0","default":false},{"id":324625182,"url":"https://api.github.com/repos/benmosher/eslint-plugin-import/labels/style-guide","name":"style-guide","color":"d4c5f9","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2017-07-08T22:16:30Z","updated_at":"2017-09-02T12:53:31Z","closed_at":null,"author_association":"NONE","body":"TSLint [has a similar rule](https://palantir.github.io/tslint/rules/no-default-export/), where it prohibits default exports. Basically this (second case generating a warning):\r\n\r\n```js\r\n// good-1.js\r\nexport function foo() {}\r\n\r\n// good-2.js\r\nfunction foo() {}\r\nexport {foo}\r\n\r\n// bad-1.js\r\nexport default function foo() {}\r\n\r\n// bad-2.js\r\nfunction foo() {}\r\nexport {foo as default}\r\n```"},"comment":{"url":"https://api.github.com/repos/benmosher/eslint-plugin-import/issues/comments/326742385","html_url":"https://github.com/benmosher/eslint-plugin-import/issues/889#issuecomment-326742385","issue_url":"https://api.github.com/repos/benmosher/eslint-plugin-import/issues/889","id":326742385,"user":{"login":"mordaha","id":800239,"avatar_url":"https://avatars1.githubusercontent.com/u/800239?v=4","gravatar_id":"","url":"https://api.github.com/users/mordaha","html_url":"https://github.com/mordaha","followers_url":"https://api.github.com/users/mordaha/followers","following_url":"https://api.github.com/users/mordaha/following{/other_user}","gists_url":"https://api.github.com/users/mordaha/gists{/gist_id}","starred_url":"https://api.github.com/users/mordaha/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mordaha/subscriptions","organizations_url":"https://api.github.com/users/mordaha/orgs","repos_url":"https://api.github.com/users/mordaha/repos","events_url":"https://api.github.com/users/mordaha/events{/privacy}","received_events_url":"https://api.github.com/users/mordaha/received_events","type":"User","site_admin":false},"created_at":"2017-09-02T12:53:31Z","updated_at":"2017-09-02T12:53:31Z","author_association":"NONE","body":"@ljharb JS module is not a thing. It is an abstraction for thinking about a project structure. \r\n\r\nIt is good to export default from library stored in npm, so consumers can choose any name they like (especially if you name you lib offensive or sexist!))\r\n\r\n```\r\nimport NiceName from 'ugly-name-lib';\r\n```\r\n\r\nBut in a project with naming conventions and rules it is a dangerous freedom.\r\n\r\nWhat names the module exports - that names should be used, and when you refactored that names - you should refactor every name in consuming modules in your project.\r\n\r\nGood rule for application projects. TS-team right.\r\n"}}
{"actor":{"display_login":"mordaha"}}