From c16ce1de8e8c21ad2136335d3b0b7d230e6d2f24 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 13 Jan 2017 12:16:00 +0100 Subject: Client: add basic aot support --- client/src/polyfills.browser.ts | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 client/src/polyfills.browser.ts (limited to 'client/src/polyfills.browser.ts') diff --git a/client/src/polyfills.browser.ts b/client/src/polyfills.browser.ts new file mode 100644 index 000000000..65e211459 --- /dev/null +++ b/client/src/polyfills.browser.ts @@ -0,0 +1,39 @@ +// Polyfills +// (these modules are what are in 'angular2/bundles/angular2-polyfills' so don't use that here) + +require('intl'); +require('intl/locale-data/jsonp/en.js'); +import 'ie-shim'; // Internet Explorer + +// Prefer CoreJS over the polyfills above +import 'core-js/es6/symbol'; +import 'core-js/es6/object'; +import 'core-js/es6/function'; +import 'core-js/es6/parse-int'; +import 'core-js/es6/parse-float'; +import 'core-js/es6/number'; +import 'core-js/es6/math'; +import 'core-js/es6/string'; +import 'core-js/es6/date'; +import 'core-js/es6/array'; +import 'core-js/es6/regexp'; +import 'core-js/es6/map'; +import 'core-js/es6/set'; +import 'core-js/es6/weak-map'; +import 'core-js/es6/weak-set'; +import 'core-js/es6/typed'; +import 'core-js/es6/reflect'; +// see issue https://github.com/AngularClass/angular2-webpack-starter/issues/709 +// import 'core-js/es6/promise'; + +import 'core-js/es7/reflect'; +import 'zone.js/dist/zone'; + +// Typescript emit helpers polyfill +import 'ts-helpers'; + +if ('production' !== ENV) { + Error.stackTraceLimit = Infinity; + + require('zone.js/dist/long-stack-trace-zone'); +} -- cgit v1.2.3