{"action":"opened","issue":{"url":"https://api.github.com/repos/vuejs/eslint-plugin-vue/issues/436","repository_url":"https://api.github.com/repos/vuejs/eslint-plugin-vue","labels_url":"https://api.github.com/repos/vuejs/eslint-plugin-vue/issues/436/labels{/name}","comments_url":"https://api.github.com/repos/vuejs/eslint-plugin-vue/issues/436/comments","events_url":"https://api.github.com/repos/vuejs/eslint-plugin-vue/issues/436/events","html_url":"https://github.com/vuejs/eslint-plugin-vue/issues/436","id":306487968,"number":436,"title":"Possible conflict with vscode-eslint when using ...mapGetters/...mapActions","user":{"login":"lbssousa","id":1277917,"avatar_url":"https://avatars0.githubusercontent.com/u/1277917?v=4","gravatar_id":"","url":"https://api.github.com/users/lbssousa","html_url":"https://github.com/lbssousa","followers_url":"https://api.github.com/users/lbssousa/followers","following_url":"https://api.github.com/users/lbssousa/following{/other_user}","gists_url":"https://api.github.com/users/lbssousa/gists{/gist_id}","starred_url":"https://api.github.com/users/lbssousa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lbssousa/subscriptions","organizations_url":"https://api.github.com/users/lbssousa/orgs","repos_url":"https://api.github.com/users/lbssousa/repos","events_url":"https://api.github.com/users/lbssousa/events{/privacy}","received_events_url":"https://api.github.com/users/lbssousa/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-03-19T14:33:09Z","updated_at":"2018-03-19T14:33:09Z","closed_at":null,"author_association":"NONE","body":"<!--\r\n    This template is for bug reports. If you are reporting a bug, please continue on. If you are here for another reason, please see below:\r\n\r\n    1. To propose a new rule: http://eslint.org/docs/developer-guide/contributing/new-rules\r\n    2. To request a change: http://eslint.org/docs/developer-guide/contributing/changes\r\n\r\n    Note that leaving sections blank will make it difficult for us to troubleshoot and we may have to close the issue.\r\n-->\r\n\r\n**Tell us about your environment**\r\n\r\n* **ESLint Version:** 4.15.0\r\n* **eslint-plugin-vue Version:** 4.0.0\r\n* **vscode-eslint extension Version:** 1.4.7\r\n* **Node Version:** 8.10.0\r\n\r\n**Please show your full configuration:**\r\n\r\n<!-- Paste your configuration below: -->\r\n```\r\nmodule.exports = {\r\n  root: true,\r\n  parserOptions: {\r\n    parser: 'babel-eslint',\r\n    sourceType: 'module'\r\n  },\r\n  env: {\r\n    browser: true\r\n  },\r\n  extends: [\r\n    // https://github.com/vuejs/eslint-plugin-vue#priority-a-essential-error-prevention\r\n    // consider switching to `plugin:vue/strongly-recommended` or `plugin:vue/recommended` for stricter rules.\r\n    'plugin:vue/strongly-recommended',\r\n    'prettier',\r\n    // https://github.com/standard/standard/blob/master/docs/RULES-en.md\r\n    'standard'\r\n  ],\r\n  // required to lint *.vue files\r\n  plugins: ['vue'],\r\n  globals: {\r\n    ga: true, // Google Analytics\r\n    cordova: true,\r\n    __statics: true\r\n  },\r\n  // add your custom rules here\r\n  rules: {\r\n    // allow async-await\r\n    'generator-star-spacing': 'off',\r\n\r\n    // allow paren-less arrow functions\r\n    'arrow-parens': 0,\r\n    'one-var': 0,\r\n\r\n    'import/first': 0,\r\n    'import/named': 2,\r\n    'import/namespace': 2,\r\n    'import/default': 2,\r\n    'import/export': 2,\r\n    'import/extensions': 0,\r\n    'import/no-unresolved': 0,\r\n    'import/no-extraneous-dependencies': 0,\r\n\r\n    // allow debugger during development\r\n    'no-debugger': process.env.NODE_ENV === 'production' ? 2 : 0\r\n  }\r\n}\r\n```\r\n\r\n**What did you do? Please include the actual source code causing the issue.**\r\nFirst of all, I'm not sure if this is a problem with eslint-plugin-vue or with vscode-eslint extension.\r\n\r\nI have some Vue components where I map Vuex getters&actions to computed properties, like this example:\r\n<!-- Paste the source code below: -->\r\n```vue\r\n<script>\r\nimport { mapActions, mapGetters } from 'vuex'\r\n\r\nexport default {\r\n  computed: {\r\n    foo: {\r\n      ...mapGetters({ get: 'getFoo' }),\r\n      ...mapActions({ set: 'setFoo' })\r\n    }\r\n  }\r\n}\r\n</script>\r\n```\r\n\r\nHowever, vscode-eslint throws several exceptions when I write computed properties based on such mappings.\r\n\r\n**What did you expect to happen?**\r\nI expect that vscode-eslint can lint my code successfully\r\n\r\n**What actually happened? Please include the actual, raw output from ESLint.**\r\nI've got the following exception from vscode-eslint:\r\n\r\n```\r\n[Error - 10:56:24] ESLint stack trace:\r\n[Error - 10:56:24] TypeError: Cannot read property 'type' of undefined\r\n    at cp.value.properties.filter.p (/home/laercio/Documentos/GitLab/pte-mogidascruzes/mae-electron-quasar/node_modules/eslint-plugin-vue/lib/utils/index.js:347:20)\r\n    at Array.filter (native)\r\n    at computedPropertiesNode.value.properties.filter.map.cp (/home/laercio/Documentos/GitLab/pte-mogidascruzes/mae-electron-quasar/node_modules/eslint-plugin-vue/lib/utils/index.js:346:14)\r\n    at Array.map (native)\r\n    at Object.getComputedProperties (/home/laercio/Documentos/GitLab/pte-mogidascruzes/mae-electron-quasar/node_modules/eslint-plugin-vue/lib/utils/index.js:338:8)\r\n    at Object.assign.utils.executeOnVue (/home/laercio/Documentos/GitLab/pte-mogidascruzes/mae-electron-quasar/node_modules/eslint-plugin-vue/lib/rules/no-async-in-computed-properties.js:118:40)\r\n    at ExportDefaultDeclaration:exit (/home/laercio/Documentos/GitLab/pte-mogidascruzes/mae-electron-quasar/node_modules/eslint-plugin-vue/lib/utils/index.js:467:9)\r\n    at listeners.(anonymous function).forEach.listener (/home/laercio/Documentos/GitLab/pte-mogidascruzes/mae-electron-quasar/node_modules/eslint/lib/util/safe-emitter.js:47:58)\r\n    at Array.forEach (native)\r\n    at Object.emit (/home/laercio/Documentos/GitLab/pte-mogidascruzes/mae-electron-quasar/node_modules/eslint/lib/util/safe-emitter.js:47:38)\r\n```\r\n\r\n**Possible workaround**\r\nWith this workaround, vscode-eslint stops throwing the exceptions above and lints my code successfully.\r\n\r\n```vue\r\n<script>\r\nimport { mapActions, mapGetters } from 'vuex'\r\n\r\nconst compProps = {\r\n  foo: {\r\n    ...mapGetters({ get: 'foo' }),\r\n    ...mapActions({ set: 'foo' })\r\n  }\r\n}\r\n\r\nexport default {\r\n  computed: {\r\n    ...compProps\r\n  }\r\n}\r\n</script>\r\n```\r\n"}}
{"actor":{"display_login":"lbssousa"}}