-
Notifications
You must be signed in to change notification settings - Fork 519
Add EventSource polyfill so that webpack HMR can work on IE/Edge #365
Comments
Is this something new they implemented? Thought it always worked with IE! |
EventSource doesn't work in IE, and is still just in "Under Consideration" status for Edge. I've looked at this a bit before, I think this might be the most popular polyfill - it's been maintained for 4+ years and supports a lot of browsers, including IE11 and Edge. |
Thanks @jongalloway - have added that one and it works. |
…siderable majority of aspnet-webpack users)
I'm confused. I just downloaded the template pack and started it up in IE and Edge and neither have the event-source polyfill added by default. I added it to the webpack.config.vendor.js manually and there's no difference. |
How do you know this? Are you seeing this message in the browser's console when you refresh your page?
|
Yes I'm seeing the message in the browser console in both Edge and IE. Yes I should include a polyfill. Actually a Microsoft development effort should include the polyfill by default because you know YOUR browsers don't work without it and telling people to use GOOGLE'S browser in a Microsoft development environment is STUPID on Microsoft's part because it ensures that developers don't need your tools at all and thus have no reason to develop on Windows or use Visual Studio. But I digress... As I noted I added the npm for eventsource-polyfill from the page you noted and then put it in the webpack.vendor.config.js file in the vendors section. It doesn't complain but after rebuilding the webpack file and running it again, there is no difference at all and the error message still shows up in the console for both IE and Edge. So yes, your templates should have this and any other polyfills for IE 11+ development installed automatically. (or at the very least give a options box when you create the template) Further if you're going to instruct someone to "include a polyfill" it might be helpful to tell them HOW to do so given the complexity of how this project is setup versus instructional materials on webpack's site, and even MVC.net etc. |
The latest template does include the If you want to run the latest template, please use the Yeoman generator ( |
@SteveSandersonMS I am using the latest template (for Aurelia) and it does not include a dependency on the eventsource-polyfill. . |
Currently, HMR fails on IE/Edge because http://caniuse.com/#feat=eventsource
The text was updated successfully, but these errors were encountered: