After upgrade webpack from version 4 to 5 I have problem with IE 11. I have all chunks in path '/' and I have one script with code:
var url = './assets/js/vendor/library/lib.js'
var script = document.createElement('script')
script.src = url
script.async = true
document.getElementsByTagName('head')[0].appendChild(script)
After executing the above code, the browser starts trying to fetch chunks from the path '/assets/js/vendor/library/chunk.js', not from '/chunk.js' even lib.js is empty file. In Chrome everything works fine. When I comment on the above code, everything starts to work.
Variable window.location.pathname is setted correctly to '/'.