buttplugio / buttplug-rs-ffi

FFI from buttplug-rs to Java and other languages
Other
88 stars 22 forks source link

CDN Loading can break when script tags use defer #57

Open qdot opened 3 years ago

qdot commented 3 years ago

Describe the bug

  1. Create an HTML page that loads the CDN buttplug distro, uses defer in the script tag, and has other includes from different domains after it.

Expected behavior Things load fine

Actual behavior Chunks can't be found because they end up with the domain of the last script tag

Additional context The publicpath override for webpack tries to load the URL of the last script tag, but if defer is used, all tags are loaded before script tags actually fetch their scripts. This means we'll take the URL of whatever the content for the last script tag is.