{"action":"created","issue":{"url":"https://api.github.com/repos/ktsn/vue-template-loader/issues/5","repository_url":"https://api.github.com/repos/ktsn/vue-template-loader","labels_url":"https://api.github.com/repos/ktsn/vue-template-loader/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/ktsn/vue-template-loader/issues/5/comments","events_url":"https://api.github.com/repos/ktsn/vue-template-loader/issues/5/events","html_url":"https://github.com/ktsn/vue-template-loader/issues/5","id":198446955,"number":5,"title":"Conflict with webpack-html-plugin","user":{"login":"sqal","id":3576913,"avatar_url":"https://avatars.githubusercontent.com/u/3576913?v=3","gravatar_id":"","url":"https://api.github.com/users/sqal","html_url":"https://github.com/sqal","followers_url":"https://api.github.com/users/sqal/followers","following_url":"https://api.github.com/users/sqal/following{/other_user}","gists_url":"https://api.github.com/users/sqal/gists{/gist_id}","starred_url":"https://api.github.com/users/sqal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sqal/subscriptions","organizations_url":"https://api.github.com/users/sqal/orgs","repos_url":"https://api.github.com/users/sqal/repos","events_url":"https://api.github.com/users/sqal/events{/privacy}","received_events_url":"https://api.github.com/users/sqal/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2017-01-03T10:34:16Z","updated_at":"2017-01-04T11:16:56Z","closed_at":null,"body":"Using this loader with webpack-html-plugin leads to this error:\r\n\r\n```\r\nERROR in   Error: Child compilation failed:\r\ntemplate syntax error Templates should only be responsible for mapping the state to the UI. Avoid placing tags with\r\n side-effects in your templates, such as <script>, as they will not be parsed.:\r\ntemplate syntax error Templates should only be responsible for mapping the state to the UI. Avoid placing tags with\r\n side-effects in your templates, such as <script>, as they will not be parsed.\r\n\r\n- compiler.js:76\r\n  [ProjectName]/[html-webpack-plugin]/lib/compiler.js:76:16\r\n\r\n- Compiler.js:282 Compiler.<anonymous>\r\n  [ProjectName]/[webpack]/lib/Compiler.js:282:10\r\n\r\n- Compiler.js:479\r\n  [ProjectName]/[webpack]/lib/Compiler.js:479:13\r\n\r\n- Tapable.js:102 next\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:102:11\r\n\r\n- CachePlugin.js:61 Compiler.<anonymous>\r\n  [ProjectName]/[webpack]/lib/CachePlugin.js:61:4\r\n\r\n- Tapable.js:106 Compiler.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:106:13\r\n\r\n- Compiler.js:476\r\n  [ProjectName]/[webpack]/lib/Compiler.js:476:10\r\n\r\n- Tapable.js:95 Compilation.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:95:46\r\n\r\n- Compilation.js:625\r\n  [ProjectName]/[webpack]/lib/Compilation.js:625:18\r\n\r\n- Tapable.js:95 Compilation.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:95:46\r\n\r\n- Compilation.js:616\r\n  [ProjectName]/[webpack]/lib/Compilation.js:616:10\r\n\r\n- Tapable.js:95 Compilation.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:95:46\r\n\r\n- Compilation.js:611\r\n  [ProjectName]/[webpack]/lib/Compilation.js:611:9\r\n\r\n- Tapable.js:95 Compilation.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:95:46\r\n\r\n- Compilation.js:607 sealPart2\r\n  [ProjectName]/[webpack]/lib/Compilation.js:607:8\r\n\r\n- Tapable.js:95 Compilation.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:95:46\r\n\r\n- From previous event:\r\n\r\n- compiler.js:69 Object.compileTemplate\r\n  [ProjectName]/[html-webpack-plugin]/lib/compiler.js:69:10\r\n\r\n- index.js:47 Compiler.<anonymous>\r\n  [ProjectName]/[html-webpack-plugin]/index.js:47:40\r\n\r\n- Tapable.js:193 Compiler.applyPluginsParallel\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:193:14\r\n\r\n- Compiler.js:468\r\n  [ProjectName]/[webpack]/lib/Compiler.js:468:8\r\n\r\n- Tapable.js:95 Compiler.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:95:46\r\n\r\n- Compiler.js:461 Compiler.compile\r\n  [ProjectName]/[webpack]/lib/Compiler.js:461:7\r\n\r\n- Compiler.js:47\r\n  [ProjectName]/[webpack]/lib/Compiler.js:47:17\r\n\r\n- Tapable.js:102 next\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:102:11\r\n\r\n- Shared.js:138 Compiler.compilerInvalid\r\n  [ProjectName]/[webpack-dev-middleware]/lib/Shared.js:138:5\r\n\r\n- Tapable.js:104 next\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:104:14\r\n\r\n- CachePlugin.js:31 Compiler.<anonymous>\r\n  [ProjectName]/[webpack]/lib/CachePlugin.js:31:4\r\n\r\n- Tapable.js:106 Compiler.applyPluginsAsyncSeries\r\n  [ProjectName]/[webpack]/[tapable]/lib/Tapable.js:106:13\r\n\r\n- Compiler.js:45 Watching._go\r\n  [ProjectName]/[webpack]/lib/Compiler.js:45:16\r\n\r\n- Compiler.js:36 Watching.<anonymous>\r\n  [ProjectName]/[webpack]/lib/Compiler.js:36:8\r\n\r\n- Compiler.js:371 Compiler.readRecords\r\n  [ProjectName]/[webpack]/lib/Compiler.js:371:10\r\n\r\n- Compiler.js:33 new Watching\r\n  [ProjectName]/[webpack]/lib/Compiler.js:33:16\r\n\r\n- Compiler.js:205 Compiler.watch\r\n  [ProjectName]/[webpack]/lib/Compiler.js:205:17\r\n\r\n- Shared.js:153 Object.startWatch\r\n  [ProjectName]/[webpack-dev-middleware]/lib/Shared.js:153:29\r\n\r\n- Shared.js:215 Shared\r\n  [ProjectName]/[webpack-dev-middleware]/lib/Shared.js:215:8\r\n```\r\n\r\nThe fix is easy, just tell webpack and vue-template-loader to include only files from source directory or to exclude index.hml if it is in `src` as well:\r\n\r\n```\r\n{\r\n  test: /\\.html$/,\r\n  include: [\r\n    path.resolve('src')\r\n  ],\r\n  loader: 'vue-template-loader' \r\n}\r\n```\r\n\r\nMaybe it's worth to mention about this in the readme?"},"comment":{"url":"https://api.github.com/repos/ktsn/vue-template-loader/issues/comments/270348894","html_url":"https://github.com/ktsn/vue-template-loader/issues/5#issuecomment-270348894","issue_url":"https://api.github.com/repos/ktsn/vue-template-loader/issues/5","id":270348894,"user":{"login":"ktsn","id":2194624,"avatar_url":"https://avatars.githubusercontent.com/u/2194624?v=3","gravatar_id":"","url":"https://api.github.com/users/ktsn","html_url":"https://github.com/ktsn","followers_url":"https://api.github.com/users/ktsn/followers","following_url":"https://api.github.com/users/ktsn/following{/other_user}","gists_url":"https://api.github.com/users/ktsn/gists{/gist_id}","starred_url":"https://api.github.com/users/ktsn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ktsn/subscriptions","organizations_url":"https://api.github.com/users/ktsn/orgs","repos_url":"https://api.github.com/users/ktsn/repos","events_url":"https://api.github.com/users/ktsn/events{/privacy}","received_events_url":"https://api.github.com/users/ktsn/received_events","type":"User","site_admin":false},"created_at":"2017-01-04T11:16:56Z","updated_at":"2017-01-04T11:16:56Z","body":"Thanks for the further information and the reproduction.\r\nBut as this behavior seems to be expected on html-webpack-plugin and [it is already noted on the readme](https://github.com/ampedandwired/html-webpack-plugin#writing-your-own-templates), I think it is not related to this loader."}}
{"actor":{"display_login":"ktsn"}}