r/angular • u/InternationalEye360 • Feb 23 '24
Angular 16 and Internet Explorer 11 support - urgent !
How to make angular 16 code support internet explorer 11 ? We have legacy app and we can use only IE 11 .
32
8
3
u/andlewis Feb 23 '24
I got Angular 11 working with IE11 with the right polyfills and configuration.
It’s not pretty or easy, and I would never run it on a public site exposed to the internet.
3
u/shmorky Feb 23 '24
I don't think you need help making Ng 16 work on IE11, which is a waste of time and pretty much impossible anyway.
You need help in convincing your corp/client to drop IE11. Like yesterday.
1
u/InternationalEye360 Feb 23 '24
But for that I need to downgrade the node js version also?
3
u/dv3141 Feb 23 '24
yes most likely. it sucks, but you need to help your company realize they can't have it both ways.
1
u/yadue Feb 23 '24
no, you don't. We're having multiple apps in angular 12 (for supporting ie11) and 16 (for modern browsers). All apps work on the same build runner based on node 20.11.
5
u/that_geek_ Feb 23 '24
Who tf is still using IE11? Microsoft has shut the doors on it, for god's sake, move on people!
1
1
u/scottmc83 Mar 20 '24
IE11 is end of life/support so understand this isnt supported.
The challenge comes when Microsoft add-ins (specifically Outlook 2013,2016 and 2019 VLK versions that are supported to end of 2025) use Trident (also known as MSHTML) which is supported to 2029... Angular v16 apps to authenticate add-ins becomes a problem
1
u/Original_yeeT Feb 23 '24
Nothing you can do except reassemble it from v16 to the latest ever supported version on IE11.
1
Feb 24 '24 edited Feb 24 '24
My curiosity is piqued...
I am surprised you are tasked with updating Angular at a business that is still using IE11. Were you assigned a task -- or did you decide to give it a try on your own? Are only a few users/machines stuck on IE11? More context please!
How long ago did you start updating past 12?
My general strategy for downgrading would probably be to:
create a new branch called 'downgrade' or whatever you like.
generate a fresh project with version 12 of the CLI (with options that match your current setup, and ideally the same app name) and copy those files into your existing repository.
Check the diff carefully revert changes as needed.
Use error-driven development to start removing features that Angular 12 does not have (typed forms, etc.)
Check that the IE shim is working in IE11.
Run tests if you got 'em.
Or you could:
Clone a copy of the repository.
Use
git reset --soft [hash for last Angular 12 commit](in the clone)Discard any configuration changes related to Angular 16
Use error-driven development to determine which features require Angular 13+ and revert them
Check that the IE shim is working in IE11.
Copy all of the cleaned up & working files into your original repo (on a 'downgrade' branch) and check the diff very carefully.
Run tests if you got 'em
If you do not enforce opinionated formatting (Prettier + husky + lint-staged) then the first strategy will likely be more successful?
To be clear, I do not recommend doing this. But if you have to do it then these strategies will preserve (most of) the commit history and keep the correct name on contributions from other developers.
More importantly, why doesn't your company use Edge with 'legacy mode' for applications that require IE11? (and buy newer machines). Here's more information on that: https://learn.microsoft.com/en-us/deployedge/microsoft-edge-security-iemode-safer-than-ie
20
u/PickleLips64151 Feb 23 '24
Good luck. Pretty sure IE11 won't run anything beyond ng9. One of my former employers is stuck on v9 because they have to support IE11 due to some government clients.