This repository was archived by the owner on Dec 14, 2018. It is now read-only.
This repository was archived by the owner on Dec 14, 2018. It is now read-only.
Add an Option to set the Razor view location formats #4550
Closed
Description
To customize the set of path formats that the Razor view engine will look at you need to customize the view engine itself. You need to either derive from RazorViewEngine, override the list of formats, and add that to the list of view engines, or you have to instantiate RazorViewEngine itself, set the list of formats, and add that to the list of view engines.
This is the property in question:
(Plus the one for areas.)
We already have a Razor View Options class (https://github.com/aspnet/Mvc/blob/af58c2e6b619697a1a57736e9e996bb4d7e6e7ee/src/Microsoft.AspNetCore.Mvc.Razor/RazorViewEngineOptions.cs) so we should have the default list of view location formats there instead.