Open
Description
Description
Update the following code to use a manifest file and replace any app.UseStaticFiles(new StaticFileOptions
code with
var myManifestKey = builder.Configuration["MyManifestPath"]
?? "manifests/manifest.json";
/// other code
app.MapStaticAssets(staticAssetsManifestPath: myManifestKey);
Helpful links:
- The new format of manifest file
- StaticAssetsIntegrationTests.cs
- StaticAssetsManifest
- StaticAssetsManifestPath
- StaticAssetsEndpointRouteBuilderExtensions
Page URL
https://learn.microsoft.com/en-us/aspnet/core/fundamentals/static-files?view=aspnetcore-8.0
Content source URL
https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/fundamentals/static-files.md
Document ID
3fec6e08-fc99-7a5c-796f-3f2347cad891