Why is the size of the same js file loaded in CDN different from that loaded locally?

for example, the load size of ag-grid.js on cdn is about 300KB, and the address is as follows: https://unpkg.com/ag-grid-com.

.

download the same file on github and import it to the local server with the size of 2.3MB

I don"t quite understand the related concepts of CDN. Why is there such a big difference? I know that Zaipaiyun has intelligent compression services such as GZIP. Is that the reason?

Cdn
Aug.24,2021

is the open Gzip

clipboard.png


the first time you access a file should be the same, but when you access cdn the second time, from cache/from disk. will be displayed Is that what you're talking about?

Menu