you can set the default render item, in a Composer . (which is part of the new startup routines) - your RenderController needs to implement IRenderMvcController (which is auto-discovered so you don't need to add that explicity to a composition)
public class MyComposer : IUserComposer
{
public void Compose(Composition composition)
{
composition.SetDefaultRenderMvcController(typeof(MyMvcController));
}
}
public class MyMvcController : IRenderMvcController
{
public void Execute(RequestContext requestContext)
{
throw new NotImplementedException();
}
public ActionResult Index(ContentModel model)
{
throw new NotImplementedException();
}
}
DefaultRenderMvcControllerResolver
How do you implement a similar feature like DefaultRenderMvcControllerResolver in Umbraco8?
https://our.umbraco.com/documentation/Reference/Routing/custom-controllers
I was looking into UmbracoControllerFactory and RenderControllerFactory.
Hi Carl,
you can set the default render item, in a Composer . (which is part of the new startup routines) - your RenderController needs to implement IRenderMvcController (which is auto-discovered so you don't need to add that explicity to a composition)
Nice! Thanks.
Can't wait for more documentaion on version 8.
is working on a reply...