{"action":"created","issue":{"url":"https://api.github.com/repos/xjamundx/eslint-plugin-promise/issues/2","repository_url":"https://api.github.com/repos/xjamundx/eslint-plugin-promise","labels_url":"https://api.github.com/repos/xjamundx/eslint-plugin-promise/issues/2/labels{/name}","comments_url":"https://api.github.com/repos/xjamundx/eslint-plugin-promise/issues/2/comments","events_url":"https://api.github.com/repos/xjamundx/eslint-plugin-promise/issues/2/events","html_url":"https://github.com/xjamundx/eslint-plugin-promise/issues/2","id":128404173,"number":2,"title":"Add rule: must define \"Promise\"","user":{"login":"gajus","id":973543,"avatar_url":"https://avatars.githubusercontent.com/u/973543?v=3","gravatar_id":"","url":"https://api.github.com/users/gajus","html_url":"https://github.com/gajus","followers_url":"https://api.github.com/users/gajus/followers","following_url":"https://api.github.com/users/gajus/following{/other_user}","gists_url":"https://api.github.com/users/gajus/gists{/gist_id}","starred_url":"https://api.github.com/users/gajus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gajus/subscriptions","organizations_url":"https://api.github.com/users/gajus/orgs","repos_url":"https://api.github.com/users/gajus/repos","events_url":"https://api.github.com/users/gajus/events{/privacy}","received_events_url":"https://api.github.com/users/gajus/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2016-01-24T15:18:52Z","updated_at":"2016-05-25T16:06:15Z","closed_at":null,"body":"A very common error in large project is to use `Promise` without importing it. This can be caught only when testing in an environment that does not declare global variable `Promise` (e.g. IE10). Therefore, I always require that developer import `Promise` to the local scope, e.g.,\r\n\r\n```js\r\nimport Promise from 'bluebird';\r\n// or\r\nlet Promise = require('bluebird');\r\n\r\nexport default Promise.resolve(null);\r\n```\r\n\r\nNo need check what is being imported as long as `Promise` variable is defined.\r\n\r\nThis rule must cause error only when `Promise` variable is used in the document."},"comment":{"url":"https://api.github.com/repos/xjamundx/eslint-plugin-promise/issues/comments/221624526","html_url":"https://github.com/xjamundx/eslint-plugin-promise/issues/2#issuecomment-221624526","issue_url":"https://api.github.com/repos/xjamundx/eslint-plugin-promise/issues/2","id":221624526,"user":{"login":"xjamundx","id":246143,"avatar_url":"https://avatars.githubusercontent.com/u/246143?v=3","gravatar_id":"","url":"https://api.github.com/users/xjamundx","html_url":"https://github.com/xjamundx","followers_url":"https://api.github.com/users/xjamundx/followers","following_url":"https://api.github.com/users/xjamundx/following{/other_user}","gists_url":"https://api.github.com/users/xjamundx/gists{/gist_id}","starred_url":"https://api.github.com/users/xjamundx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xjamundx/subscriptions","organizations_url":"https://api.github.com/users/xjamundx/orgs","repos_url":"https://api.github.com/users/xjamundx/repos","events_url":"https://api.github.com/users/xjamundx/events{/privacy}","received_events_url":"https://api.github.com/users/xjamundx/received_events","type":"User","site_admin":false},"created_at":"2016-05-25T16:06:15Z","updated_at":"2016-05-25T16:06:15Z","body":"Finally going to work on this"}}
{"actor":{"display_login":"xjamundx"}}