Skip to content
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.

Layout not rendered via ViewStart.cshtml: Question on Razor View discovery in .Net Core preview 1 #6448

@Ponant

Description

@Ponant

Hi,
I was using a simple but otherwise great library in .Net Core 1.1 by Scott Allen https://github.com/OdeToCode/AddFeatureFolders/ that allows one to put controllers and views in a Feature-folder architecture. The View discovery of this NuGet was working perfectly fine in 1.1, but implementing this architecture in .Net Core 2.0 Preview 1 makes the Layout View via ViewStart.cshtml not discoverable. I tested this with an empty template from preview 1 with the minimum required (one controller one view, one shared folder hosting a layout, and one viewstart and viewimport). The workaround is to call Layout="_Layout" from the view to be rendered in RenderBody() (e.g. Index view of a Home controller) OdeToCode/AddFeatureFolders#16.
Thus my question: is there any change that occurred to the view engine since 1.1 you can point me to and that could be at the origin of this malfunctioning? I have seen some comments but they seem to concern Razor pages only
#6308
#6428

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions