If I understand correctly, you are asking how to disable the cache IIS cache in JS
var adminManager = new ActiveXObject('Microsoft.ApplicationHost.WritableAdminManager');
adminManager.CommitPath = "MACHINE/WEBROOT/APPHOST/Default Web Site";
var staticContentSection = adminManager.GetAdminSection("system.webServer/staticContent", "MACHINE/WEBROOT/APPHOST/Default Web Site");
var clientCacheElement = staticContentSection.ChildElements.Item("clientCache");
clientCacheElement.Properties.Item("cacheControlMode").Value = "DisableCache";
adminManager.CommitChanges();
Or via web.config to disable caching of requests:
<configuration>
<system.webServer>
<staticContent>
<clientCache cacheControlMode="DisableCache" />
</staticContent>
</system.webServer>
</configuration>
Ref: https://docs.microsoft.com/en-us/iis/configuration/system.webserver/staticcontent/clientcache
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…