WebOptimizer
WebOptimizer copied to clipboard
Longhand Coding Path/Name To UseWebOptimizer?
Can anyone tell me why I can't get a longhand approach to implementing UseWebOptimizer.
I know the first question for probably everyone is "why". I just like elongating my code so I have an intimate knowledge of what I'm doing. That is my "why".
Now with that said, I know, with the appropriate "using" statements, I can easily go about it via "app.UseWebOptimizer". But without those statements, what is the longhand approach?
For example, before removing the "using" statements, I can F12 on UseHsts and see the longhand for that would be:
Microsoft.AspNetCore.Builder.HstsBuilderExtensions.UseHsts(app);
But for some reason, I can't F12 on UseWebOptimizer.
When looking at the source code I can see it under "Microsoft.AspNetCore.Builder.ApplicationBuilderExtensions", but even if I try to force it with:
Microsoft.AspNetCore.Builder.ApplicationBuilderExtensions.UseWebOptimizer(app);
... it borks with:
The type 'ApplicationBuilderExtensions' exists in both 'Microsoft.AspNetCore.Localization, Version=5.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' and 'WebOptimizer.Core, Version=3.0.250.0, Culture=neutral, PublicKeyToken=null'
Thinking about it more, I think it would be more appropriate to change the name of the "public static class ApplicationBuilderExtensions" to something like "public static class WebOptimizerBuilderExtensions", much like "Microsoft.AspNetCore.Builder.HstsBuilderExtensions.UseHsts".