Angular4 Application running issues in IE11

Terry Zhang picture Terry Zhang · Jul 27, 2017 · Viewed 37.2k times · Source

I am building a Angular4 project using Angular CLI (1.1.2). It runs perfectly in Chrome (Version 59.0.3071.115) and firefox(54.0.1) but when I tried to use IE11 (Verison 11.0.9600.18738) nothings shows up and when I open the develper mode in IE, it shows me the following Error:

SCRIPT5022: Exception thrown and not caught
File: polyfills.bundle.js, Line: 829, Column: 34

And the detailed Error message is following:

enter image description here

Anyone knows how to solve this problem?

Thanks!

Answer

Switch picture Switch · Sep 6, 2017

To add more detail to @Zeqing's answer.

I uncommented the following line of codes in .\my-app\src\polyfills.ts :

/** IE9, IE10 and IE11 requires all of the following polyfills. **/
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';