You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
? (env.WebRootFileProvider as CompositeFileProvider).FileProviders.Last()
Umbraco10 invisibly adds a number of FileProviders, meaning that the PhysicalFileProvider one would expect to map to wwwroot was not the one used in the Sass compilation pipeline.
Specifcally re-adding a PhysicalFileProvider in after the Umbraco middleware was required in order to get things working as expected again.
IWebHostEnvironment? webHostEnvironment = app.ApplicationServices.GetService<IWebHostEnvironment>(); if (webHostEnvironment is not null) { webHostEnvironment.WebRootFileProvider = new CompositeFileProvider( new PhysicalFileProvider(env.WebRootPath), env.WebRootFileProvider); }
I'm not sure how flexible / intuitive it is that FileProviders.Last() is the one that all assets are routed through...
I'm adding this issue in case it helps anyone facing the same problem.