今天遇到问题,mark 一下:
发现 js 文件里的资源没有被 nginx 反代替换,看了站源的返回是这个格式 application/x-javascript,所以未来 subs_filter 应该监控如下类型,才可以保证 js 里的资源得到正确替换:
subs_filter_types application/json text/xml text/css text/js text/javascript application/x-gzip application/x-javascript; proxy_set_header Accept-Encoding '';
REF https://cloud.tencent.com/developer/ask/52563
分享人 admin @
2018-10-01 18:50:42
https://stackoverflow.com/questions/9664282/difference-between-application-x-javascript-and-text-javascript-content-types