Issue with view resolution with MVC project structured for vertical slice features

I have an MVC Asp .net project (.Net6) designed up to support a 3 level structure for vertical slice features:


where the levels in square brackets [] are named as appropriate for each feature, but may also not exist

so each of the following would be valid




All works fine within asp .net at runtime with the custom IControllerModelConvention and Custom IViewLocationExpander etc. I have.

The only issue is resharper resolving the views correctly. I have tried adding the full viewlocation formats  (that have replacement points {3}, {4} and {5}, I have tried relative formats from the controller location and I have tried wildcards in the path, but the only thing that works is if I manually add the exact path each time - see below:

[assembly: AspMvcViewLocationFormat(@"\Features\{5}\{4}\{3}\{0}.cshtml")]

[assembly: AspMvcViewLocationFormat(@"\Features\*\*\*\{0}.cshtml")]

[assembly: AspMvcViewLocationFormat(@".\{0}.cshtml")]

There doesn't seem to be any documentation around what this attribute allows as the string value.

Any help warmly welcomed.



Hi Patrick T Gandy 
ReSharper supports only standard placeholders: {0} action, {1} controller, {2} area.


Such a shame, one of the most useful functions in resharper is the additional view resolution and view error support, looks like I may have to review my need.


Fell free to vote for advanced view resolution.


Please sign in to leave a comment.