{"action":"created","issue":{"url":"https://api.github.com/repos/TypeStrong/ts-loader/issues/394","repository_url":"https://api.github.com/repos/TypeStrong/ts-loader","labels_url":"https://api.github.com/repos/TypeStrong/ts-loader/issues/394/labels{/name}","comments_url":"https://api.github.com/repos/TypeStrong/ts-loader/issues/394/comments","events_url":"https://api.github.com/repos/TypeStrong/ts-loader/issues/394/events","html_url":"https://github.com/TypeStrong/ts-loader/issues/394","id":192694444,"number":394,"title":"Escaped octal literals cause problems?","user":{"login":"xogeny","id":1498808,"avatar_url":"https://avatars.githubusercontent.com/u/1498808?v=3","gravatar_id":"","url":"https://api.github.com/users/xogeny","html_url":"https://github.com/xogeny","followers_url":"https://api.github.com/users/xogeny/followers","following_url":"https://api.github.com/users/xogeny/following{/other_user}","gists_url":"https://api.github.com/users/xogeny/gists{/gist_id}","starred_url":"https://api.github.com/users/xogeny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xogeny/subscriptions","organizations_url":"https://api.github.com/users/xogeny/orgs","repos_url":"https://api.github.com/users/xogeny/repos","events_url":"https://api.github.com/users/xogeny/events{/privacy}","received_events_url":"https://api.github.com/users/xogeny/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-11-30T22:10:43Z","updated_at":"2016-11-30T22:30:46Z","closed_at":null,"body":"If I include the following code in a `.ts` file:\r\n\r\n```\r\nimport { cssRaw } from 'typestyle';\r\n\r\nexport function injectCSS() {\r\n    cssRaw(`.glyphicon-pencil:before{content:\"\\270f\"}`)\r\n}\r\n```\r\n\r\n...that is loaded with `ts-loader`, I get the following error:\r\n\r\n```\r\nERROR in ./src/style/bootstrap.ts\r\nModule parse failed: /Users/mtiller/Source/Simran/simran/node_modules/ts-loader/index.js!/Users/mtiller/Source/Simran\r\n/simran/src/style/bootstrap.ts Octal literal in strict mode (4:58)\r\nYou may need an appropriate loader to handle this file type.\r\n| const typestyle_1 = require(\"typestyle\");\r\n| function injectCSS() {\r\n|     typestyle_1.cssRaw(`.glyphicon-pencil:before{content:\"\\270f\"}`);\r\n| }\r\n| exports.injectCSS = injectCSS;\r\n```\r\n\r\nThis is with `ts-loader` version `1.2.2` (running webpack 2).  To be clear, the string in question **is quoted with backticks**.  The TypeScript compiler itself has no issue with this and the error seems to be coming from the `ts-loader/index.js` script.\r\n\r\nOf course, it is possible that this is actually a `webpack` issue and I'm barking up the wrong tree.  Just let me know if that is the case."},"comment":{"url":"https://api.github.com/repos/TypeStrong/ts-loader/issues/comments/264017470","html_url":"https://github.com/TypeStrong/ts-loader/issues/394#issuecomment-264017470","issue_url":"https://api.github.com/repos/TypeStrong/ts-loader/issues/394","id":264017470,"user":{"login":"blakeembrey","id":1088987,"avatar_url":"https://avatars.githubusercontent.com/u/1088987?v=3","gravatar_id":"","url":"https://api.github.com/users/blakeembrey","html_url":"https://github.com/blakeembrey","followers_url":"https://api.github.com/users/blakeembrey/followers","following_url":"https://api.github.com/users/blakeembrey/following{/other_user}","gists_url":"https://api.github.com/users/blakeembrey/gists{/gist_id}","starred_url":"https://api.github.com/users/blakeembrey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/blakeembrey/subscriptions","organizations_url":"https://api.github.com/users/blakeembrey/orgs","repos_url":"https://api.github.com/users/blakeembrey/repos","events_url":"https://api.github.com/users/blakeembrey/events{/privacy}","received_events_url":"https://api.github.com/users/blakeembrey/received_events","type":"User","site_admin":false},"created_at":"2016-11-30T22:30:46Z","updated_at":"2016-11-30T22:30:46Z","body":"You should be using two backticks anyway, as one backtick means you're writing an octal literal. It's not allowed according to the ES spec and it's probably Webpack trying to warn you here (it's a bummer TypeScript didn't catch it actually).\r\n\r\n![image](https://cloud.githubusercontent.com/assets/1088987/20774071/86be346a-b709-11e6-96b3-6bce087f2cf9.png)\r\n"}}
{"actor":{"display_login":"blakeembrey"}}