app.UseStaticFiles(new StaticFileOptions
{
OnPrepareResponse = ctx =>
{
ctx.Context.Response.Headers.Append("Cache-Control", "public, max-age=31536000");
}
});
上一篇:ASP.NETCore6WebAPI:如何区分HttpGet动词/操作的不同变体的路由?
下一篇:ASP.NetCore6WebApp:Nodefaultauthschemewithwindowsauthentication