{"action":"opened","issue":{"url":"https://api.github.com/repos/webpack/webpack/issues/2817","repository_url":"https://api.github.com/repos/webpack/webpack","labels_url":"https://api.github.com/repos/webpack/webpack/issues/2817/labels{/name}","comments_url":"https://api.github.com/repos/webpack/webpack/issues/2817/comments","events_url":"https://api.github.com/repos/webpack/webpack/issues/2817/events","html_url":"https://github.com/webpack/webpack/issues/2817","id":168277865,"number":2817,"title":"The SystemPlugin breaks tslib","user":{"login":"Tragetaschen","id":1947968,"avatar_url":"https://avatars.githubusercontent.com/u/1947968?v=3","gravatar_id":"","url":"https://api.github.com/users/Tragetaschen","html_url":"https://github.com/Tragetaschen","followers_url":"https://api.github.com/users/Tragetaschen/followers","following_url":"https://api.github.com/users/Tragetaschen/following{/other_user}","gists_url":"https://api.github.com/users/Tragetaschen/gists{/gist_id}","starred_url":"https://api.github.com/users/Tragetaschen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Tragetaschen/subscriptions","organizations_url":"https://api.github.com/users/Tragetaschen/orgs","repos_url":"https://api.github.com/users/Tragetaschen/repos","events_url":"https://api.github.com/users/Tragetaschen/events{/privacy}","received_events_url":"https://api.github.com/users/Tragetaschen/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-07-29T08:43:12Z","updated_at":"2016-07-29T08:43:12Z","closed_at":null,"body":"**I'm submitting a bug report**\r\n\r\n**Webpack version:**\r\n2.1.0-beta.20\r\n\r\n\r\n**Please tell us about your environment:**\r\nWindows 10\r\n\r\n\r\n**Current behavior:**\r\ntslib might register itself with SystemJS [when available](https://github.com/Microsoft/tslib/blob/master/tslib.js#L24).\r\nThe SystemPlugin replaces the first check of that line with `\"object\" === \"object\"` so at runtime (without SystemJS) the second check throws.\r\n\r\nNote that the next check for AMD is also rewritten entirely (`else if (true)`)\r\n\r\n**Expected/desired behavior:**\r\nThe plugin shouldn't break tslib.\r\n\r\n* **If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem along with a gist/jsbin of your webpack configuration.** \r\nA single `import 'tslib';` typescript entry point results in the broken check.\r\n\r\n* **What is the expected behavior?**\r\nWhy do you ask a second time?\r\n\r\n* **What is the motivation / use case for changing the behavior?**\r\nSo it doesn't break\r\n \r\n* **Browser:** [all <s>| Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView </s>] \r\n \r\n* **Language:** [all | TypeScript X.X | ES6/7 | ES5 | Dart | ...] \r\nWhat?"}}
{"actor":{"display_login":"Tragetaschen"}}