-
Notifications
You must be signed in to change notification settings - Fork 110
Closed
Description
Here are five important reasons why shipping the minified version in the NPM package is a good thing:
- To support Subresource Integrity (SRI) - This is used to ensure that the copy of a file on a CDN has not been tampered with. The minified file on the CDN is compared to a local copy but for that to happen both minified copies need to be the same! If you don't provide a minified copy, then people will use their own minified file which may be different. The only way around this is to manually download the copy on the CDN instead, thus removing the need for the NPM package entirely!
- Using Uglify on jQuery outputs a larger script than the one they officially provide. They must use specific settings to get the smallest file possible.
- The minified script is the final product, not the unmodified script. All large projects provide a minified script.
- People don't want to have to fire up a build pipeline just to minify this file. An unminified copy should be provided just for the pure convenience of it!
- I just raised the same PR for jquery-validation and it was accepted.
gregfiske and VirtuaBoza