ABHILASHA K.M
ABHILASHA K.M

Reputation: 174

Angular Form not working in Internet Explorer 11

I have developed an Angular 6 Project. All is working well in Chrome, Mozilla and Apple browsers, but it is not working in Internet Explorer 11. I am unable to save the data on clicking button.

In the console(Network), when clicking the button, it's not calling the API.

Do I need any special import in angular TS file for IE11?

Upvotes: 2

Views: 366

Answers (3)

Asim Khan
Asim Khan

Reputation: 31

On the angular website it is clear written that does not support internet explorer 11 you will have to configure your angular project by using following steps written in readme file of this github page.

https://github.com/browserslist/browserslist

Upvotes: 0

Robin Dijkhof
Robin Dijkhof

Reputation: 19298

Your question does not contain enough information to give an actual answer. However, IE11 + form gave me some trouble in the past.

In my case I had to add type='submit' to the submit button and type='button' to all other buttons.

Upvotes: 0

Salahuddin Ahmed
Salahuddin Ahmed

Reputation: 5658

Go to your polyfills.ts file and find the import statements commented out under the section /** IE9, IE10 and IE11 requires all of the following polyfills. */:

// import 'classlist.js';  // Run `npm install --save classlist.js`.

Uncomment the above import to have your app working with those IE browsers but don't forget to run the following command.

npm install --save classlist.js

You might be also required to uncomment the following import:

// import 'web-animations-js';  // Run `npm install --save web-animations-js`.

And not to forget to run the following command:

npm install --save web-animations-js

EDIT

In browserslist file, you may replace not IE 9-11 with IE 9-11.

Also, in tsconfig.json file, you may replace "target": "es2015" (or whatever) with "target": "es5".

Upvotes: 2

Related Questions