the-outfield/karbon-cms — pull request #15 by danieljanczak (2014-08-22 03:15:04+00:00)
Title: Allowing better integration with MVC outside of Karbon

Hi,

Rob Moore introduced me to Karbon:-)

I have done two changes allowing for better integration with MVC outside of Karbon - they are contained in separate commits:
1. Automatic exclusion of non-Karbon routes. By default, it is always possible to use a named route to create a link going outside of Karbon context, but all default MVC methods (Html.ActionLink etc.) wouldn't create valid links. After the changes it's possible to use these methods inside of Karbon context. The changed code checks the root level of Karbon context, if a virtual path can't be matched to any items it's left for other routes (=MVC).

2. Adding Html Helper extension exposing Karbon home page - it allows to use home page outside of Karbon context (for example on other MVC pages). It only makes sense to expose Home Page, Current Page outside of Karbon context wouldn't make sense...

Cheers,
Daniel