{"action":"created","issue":{"url":"https://api.github.com/repos/vuejs/vue-class-component/issues/48","repository_url":"https://api.github.com/repos/vuejs/vue-class-component","labels_url":"https://api.github.com/repos/vuejs/vue-class-component/issues/48/labels{/name}","comments_url":"https://api.github.com/repos/vuejs/vue-class-component/issues/48/comments","events_url":"https://api.github.com/repos/vuejs/vue-class-component/issues/48/events","html_url":"https://github.com/vuejs/vue-class-component/issues/48","id":196829453,"number":48,"title":"Cannot find name 'Vue'","user":{"login":"neilsimp1","id":5589585,"avatar_url":"https://avatars.githubusercontent.com/u/5589585?v=3","gravatar_id":"","url":"https://api.github.com/users/neilsimp1","html_url":"https://github.com/neilsimp1","followers_url":"https://api.github.com/users/neilsimp1/followers","following_url":"https://api.github.com/users/neilsimp1/following{/other_user}","gists_url":"https://api.github.com/users/neilsimp1/gists{/gist_id}","starred_url":"https://api.github.com/users/neilsimp1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neilsimp1/subscriptions","organizations_url":"https://api.github.com/users/neilsimp1/orgs","repos_url":"https://api.github.com/users/neilsimp1/repos","events_url":"https://api.github.com/users/neilsimp1/events{/privacy}","received_events_url":"https://api.github.com/users/neilsimp1/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":8,"created_at":"2016-12-21T02:16:49Z","updated_at":"2016-12-22T18:29:40Z","closed_at":"2016-12-22T18:29:40Z","body":"I've just started a typescript/electron app, and after getting the basics down with normal component files, I tried switching to vue-class-component.\r\n\r\nAfter installing and changing one component over to this format and compiling with `tsc`, I'm getting:\r\n\r\n```\r\n> tsc --p tsconfig.json\r\nnode_modules/vue-class-component/lib/declarations.d.ts(3,13): error TS2304: Cannot find name 'Vue'.\r\nnode_modules/vue-class-component/lib/index.d.ts(4,38): error TS2304: Cannot find name 'Vue'.\r\nnode_modules/vue-class-component/lib/index.d.ts(4,52): error TS2503: Cannot find namespace 'Vue'.\r\nnode_modules/vue-class-component/lib/util.d.ts(3,60): error TS2503: Cannot find namespace 'Vue'.\r\nnode_modules/vue-class-component/lib/util.d.ts(3,119): error TS2304: Cannot find name 'Vue'.\r\nnode_modules/vue-class-component/lib/util.d.ts(4,60): error TS2503: Cannot find namespace 'Vue'.\r\nnode_modules/vue-class-component/lib/util.d.ts(4,134): error TS2304: Cannot find name 'Vue'.\r\n```\r\n\r\nHere's my `tsconfig.json`:\r\n```\r\n{\r\n\t\"compilerOptions\": {\r\n\t\t\"target\": \"es6\",\r\n\t\t\"moduleResolution\": \"node\",\r\n\t\t\"lib\": [\r\n\t\t\t\"dom\",\r\n\t\t\t\"es2016\"\r\n\t\t],\r\n\t\t\"rootDir\": \"src/\",\r\n\t\t\"outDir\": \"dist/\",\r\n\t\t\"module\": \"commonjs\",\r\n\t\t\"allowJs\": true,\r\n\t\t\"removeComments\": true,\r\n\t\t\"emitDecoratorMetadata\": true,\r\n\t\t\"experimentalDecorators\": true\r\n\t}\r\n}\r\n```\r\n\r\npackage.json:\r\n```\r\n\"devDependencies\": {\r\n        \"copyfiles\": \"^1.0.0\",\r\n        \"electron\": \"^1.4.12\",\r\n        \"node-sass\": \"^4.0.0\",\r\n        \"typescript\": \"^2.1.4\",\r\n        \"vue\": \"^2.1.6\",\r\n        \"vue-class-component\": \"^4.4.0\"\r\n}\r\n```\r\nsrc/package.json\r\n```\r\n\"dependencies\": {\r\n\t\"@types/electron\": \"^1.4.29\",\r\n\t\"@types/node\": \"^6.0.52\",\r\n\t\"@types/vue\": \"^1.0.31\"\r\n}\r\n```\r\n\r\nI'm roughly following the project structures from https://github.com/wspl/electron-boilerplate-typescript-vue and https://github.com/bradstewart/electron-boilerplate-vue, hence the two package.json's.\r\n\r\nAny input would be appreciated, I really want to use this plugin."},"comment":{"url":"https://api.github.com/repos/vuejs/vue-class-component/issues/comments/268860879","html_url":"https://github.com/vuejs/vue-class-component/issues/48#issuecomment-268860879","issue_url":"https://api.github.com/repos/vuejs/vue-class-component/issues/48","id":268860879,"user":{"login":"neilsimp1","id":5589585,"avatar_url":"https://avatars.githubusercontent.com/u/5589585?v=3","gravatar_id":"","url":"https://api.github.com/users/neilsimp1","html_url":"https://github.com/neilsimp1","followers_url":"https://api.github.com/users/neilsimp1/followers","following_url":"https://api.github.com/users/neilsimp1/following{/other_user}","gists_url":"https://api.github.com/users/neilsimp1/gists{/gist_id}","starred_url":"https://api.github.com/users/neilsimp1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neilsimp1/subscriptions","organizations_url":"https://api.github.com/users/neilsimp1/orgs","repos_url":"https://api.github.com/users/neilsimp1/repos","events_url":"https://api.github.com/users/neilsimp1/events{/privacy}","received_events_url":"https://api.github.com/users/neilsimp1/received_events","type":"User","site_admin":false},"created_at":"2016-12-22T18:29:40Z","updated_at":"2016-12-22T18:29:40Z","body":"Thanks, you just cleared up a lot for me. I'll take a look at your template and see if I can't figure it out from there. You've been a huge help - just another example of how awesome the Vue.js community is. I'll close this since at this point any problems I may have don't really have anything to do with my original issue."}}
{"actor":{"display_login":"neilsimp1"}}