This project is read-only.

This fluent MVC TreeView helper makes it easy to build and customize an HTML unordered-list tree from a recursive model.

Blog Updates

For updates and other topics please visit my blog at or follow me @matthidinger

View The Full Blog Post

@model List<MvcTreeView.Models.Location>

    .EmptyContent("No locations have been defined yet!")    
    .Children(m => m.ChildLocations)
    .HtmlAttributes(new { id = "tree"})
    .ChildrenHtmlAttributes(new { @class = "subItem"})
    .ItemText(m => m.Name)
            <a href="#@item.Id">@item.Name</a>

Last edited Nov 27, 2011 at 7:39 PM by mhidinger, version 2