I’m looking for "how to compress load time js file" and I try the solution of my question (I’m using Extjs).
My friend suggest this too. But, it use Apache as web server. Anybody know how to do the trick in NGINX??
My hosting uses nginx as web server and i don’t know anything about web server configuration.
sorry, if my english bad..
If you do not know anything about web server configuration, I am assuming you also do not know how/where to edit the config file.
The nginx conf file is located at
/etc/nginx/nginx.conf
(verified in Ubuntu 12.04)By default, nginx gzip module is enabled. So check from this service whether it is enabled on not using an online tool like this.
If it is disabled, add this before server {...} entry in nginx.conf
You need to use the nginx HTTP gzip or the nginx HTTP gzip static module. The static module would be helpful for content like your JavaScript libraries that rarely changes, saving you needless re-compression for every client.
I make this configuration in my nginx.config you need