From a17bc2c34e79c144b7e71ff903c16c2e68371b48 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 10 Feb 2017 10:28:11 +0100 Subject: Client: use tslib instead of ts-helpers --- client/config/webpack.dev.js | 21 +++++++++++++++++++-- client/package.json | 2 +- client/src/polyfills.browser.ts | 3 --- client/tsconfig.json | 1 + client/tsconfig.webpack.json | 1 + 5 files changed, 22 insertions(+), 6 deletions(-) (limited to 'client') diff --git a/client/config/webpack.dev.js b/client/config/webpack.dev.js index affb20f19..1e975b261 100644 --- a/client/config/webpack.dev.js +++ b/client/config/webpack.dev.js @@ -88,6 +88,24 @@ module.exports = function (env) { webtorrent: 'WebTorrent' }, + module: { + + rules: [ + { + test: /\.ts$/, + use: [ + { + loader: 'tslint-loader', + options: { + configFile: 'tslint.json' + } + } + ], + exclude: [/\.(spec|e2e)\.ts$/] + } + ] + }, + plugins: [ /** @@ -121,8 +139,7 @@ module.exports = function (env) { { name: 'zone.js', path: 'zone.js/dist/long-stack-trace-zone.js' - }, - 'ts-helpers' + } ], vendor: [ '@angular/platform-browser', diff --git a/client/package.json b/client/package.json index ad901fc67..aa38e076a 100644 --- a/client/package.json +++ b/client/package.json @@ -72,7 +72,7 @@ "source-map-loader": "^0.1.5", "string-replace-loader": "^1.0.3", "style-loader": "^0.13.1", - "ts-helpers": "^1.1.1", + "tslib": "^1.5.0", "tslint": "~4.3.1", "tslint-loader": "^3.3.0", "typescript": "~2.1.0", diff --git a/client/src/polyfills.browser.ts b/client/src/polyfills.browser.ts index 65e211459..5119cf4b9 100644 --- a/client/src/polyfills.browser.ts +++ b/client/src/polyfills.browser.ts @@ -29,9 +29,6 @@ import 'core-js/es6/reflect'; import 'core-js/es7/reflect'; import 'zone.js/dist/zone'; -// Typescript emit helpers polyfill -import 'ts-helpers'; - if ('production' !== ENV) { Error.stackTraceLimit = Infinity; diff --git a/client/tsconfig.json b/client/tsconfig.json index d70710b82..115af1f83 100644 --- a/client/tsconfig.json +++ b/client/tsconfig.json @@ -8,6 +8,7 @@ "allowSyntheticDefaultImports": true, "sourceMap": true, "noEmitHelpers": true, + "importHelpers": true, "strictNullChecks": false, "baseUrl": "./src", "paths": [ diff --git a/client/tsconfig.webpack.json b/client/tsconfig.webpack.json index e1e1bb864..1d3433bc3 100644 --- a/client/tsconfig.webpack.json +++ b/client/tsconfig.webpack.json @@ -8,6 +8,7 @@ "allowSyntheticDefaultImports": true, "sourceMap": true, "noEmitHelpers": true, + "importHelpers": true, "strictNullChecks": false, "baseUrl": "./src", "outDir": "./dist", -- cgit v1.2.3