Closed Richienb closed 5 years ago
- Cdnjs is much faster than unpkg
Do you have any statistics to back that up? Because according to unpkg: "The fast, global infrastructure that powers unpkg is generously donated by Cloudflare".
- Decrease cross domain fetches
Why is this an issue? Each asset is fetched individually either way, are they not?
- Stops unexpected behaviour caused by versions changing
True, the version should be locked down. But this can be done with unpkg as well, like this: unpkg.com/:package@:version
. (I'll actually go ahead and fix this right away)
Do you have any statistics to back that up? Because according to unpkg: "The fast, global infrastructure that powers unpkg is generously donated by Cloudflare".
Cdnjs is CloudFlare. It is the only one on the CloudFlare blog.
Why is this an issue? Each asset is fetched individually either way, are they not?
This is how a request is usually handled by a browser in the old code:
This is how a request can be handled by making all the cdn urls the same:
Alright, you've convinced me.
Thank you for the PR! May i ask why you think we should use cdnjs over unpkg?