Skip to content

Fix chunk loading in Internet Explorer.#3551

Merged
sokra merged 2 commits intowebpack:masterfrom
r0b1n:bugfix/make-chunk-loader-ieproof
Dec 22, 2016
Merged

Fix chunk loading in Internet Explorer.#3551
sokra merged 2 commits intowebpack:masterfrom
r0b1n:bugfix/make-chunk-loader-ieproof

Conversation

@r0b1n
Copy link
Copy Markdown
Contributor

@r0b1n r0b1n commented Dec 22, 2016

Appending chunk loading script moved to the end of the function.

Because of unexpected behavior in some cases IE can execute script synchronously regardless async flag. We need to setup all needed callbacks before appending script to the DOM. It make jsonp callback ready to process even synchronous chunk code.

Issue #2506

Append jsonp-caller script to the head only if everything is ready to process chunk.
Needed because IE can execute script synchronously regardless `async` flag if script cached.
@jsf-clabot
Copy link
Copy Markdown

jsf-clabot commented Dec 22, 2016

CLA assistant check
All committers have signed the CLA.

@sokra
Copy link
Copy Markdown
Member

sokra commented Dec 22, 2016

This increases bundle size and invalidates some stats tests.

Could you run this?

mocha -g "Stats"
node test/statsCases/accept-stats.js

And commit the changes.

@r0b1n
Copy link
Copy Markdown
Contributor Author

r0b1n commented Dec 22, 2016

@sokra done!

@sokra sokra merged commit 97d1dda into webpack:master Dec 22, 2016
@sokra
Copy link
Copy Markdown
Member

sokra commented Dec 22, 2016

Thanks

@jdalton jdalton mentioned this pull request Jan 11, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants