{"action":"closed","issue":{"url":"https://api.github.com/repos/eslint/eslint/issues/9766","repository_url":"https://api.github.com/repos/eslint/eslint","labels_url":"https://api.github.com/repos/eslint/eslint/issues/9766/labels{/name}","comments_url":"https://api.github.com/repos/eslint/eslint/issues/9766/comments","events_url":"https://api.github.com/repos/eslint/eslint/issues/9766/events","html_url":"https://github.com/eslint/eslint/issues/9766","id":284362277,"number":9766,"title":"Using this in an arrow function in a class","user":{"login":"jay1337","id":2118189,"avatar_url":"https://avatars2.githubusercontent.com/u/2118189?v=4","gravatar_id":"","url":"https://api.github.com/users/jay1337","html_url":"https://github.com/jay1337","followers_url":"https://api.github.com/users/jay1337/followers","following_url":"https://api.github.com/users/jay1337/following{/other_user}","gists_url":"https://api.github.com/users/jay1337/gists{/gist_id}","starred_url":"https://api.github.com/users/jay1337/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jay1337/subscriptions","organizations_url":"https://api.github.com/users/jay1337/orgs","repos_url":"https://api.github.com/users/jay1337/repos","events_url":"https://api.github.com/users/jay1337/events{/privacy}","received_events_url":"https://api.github.com/users/jay1337/received_events","type":"User","site_admin":false},"labels":[{"id":45711354,"url":"https://api.github.com/repos/eslint/eslint/labels/triage","name":"triage","color":"cc317c","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2017-12-24T13:19:14Z","updated_at":"2017-12-24T19:54:18Z","closed_at":"2017-12-24T19:54:18Z","author_association":"NONE","body":"**Tell us about your environment**\r\n\r\n* **ESLint Version:** 4.13.1\r\n* **Node Version:** 8.9.1\r\n* **npm Version:** 5.6.0\r\n\r\n**What parser (default, Babel-ESLint, etc.) are you using?** babel-eslint\r\n\r\n**Please show your full configuration:**\r\n\r\n<details>\r\n<summary>Configuration</summary>\r\n\r\n<!-- Paste your configuration below: -->\r\n```js\r\n{\r\n\textends: [\r\n\t\t'eslint:all',\r\n\t\t'plugin:import/errors',\r\n\t\t'plugin:import/warnings',\r\n\t],\r\n\tparserOptions: {\r\n\t\tecmaVersion: 6,\r\n\t\tsourceType: 'module',\r\n\t\tallowImportExportEverywhere: true,\r\n\t},\r\n\tenv: {\r\n\t\tes6: true,\r\n\t},\r\n\tparser: 'babel-eslint',\r\n}\r\n```\r\n\r\n</details>\r\n\r\n**What did you do? Please include the actual source code causing the issue, as well as the command that you used to run ESLint.**\r\n\r\n<!-- Paste the source code below: -->\r\n```js\r\nclass SomeClass {\r\n  anArrowFunctionWithThis = () => this.something = \"some text\";\r\n}\r\n```\r\n\r\n<!-- Paste the command you used to run ESLint: -->\r\n```bash\r\nnode eslint.js js_file.js\r\n```\r\n\r\n**What did you expect to happen?**\r\nNo error from `no-invalid-this` rule. This pattern is quite useful and used with React : https://reactarmory.com/answers/when-to-use-arrow-functions\r\n\r\n**What actually happened? Please include the actual, raw output from ESLint.**\r\nThere is an error: `Unexpected 'this'. (no-invalid-this)`\r\n"}}
{"actor":{"display_login":"not-an-aardvark"}}