Following nginx configuration in a server block can cache js and css files with "js" or "css" as the end of the url.
location ~ .*\.(js|css)?$ {
expires 7d;
}
But it can't cache request such as:
http: //example.com/jquery.js?ver=1.11.3&build=1
or
http: //example.com/style.css?ver=4.3&build=1
Any way to cache cs/jss files above? Or cache files based on the file type of request instead of file name?