Created
March 20, 2014 12:47
-
-
Save khalidabuhakmeh/9663021 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| PerfMatter.TitleResolver = DependencyResolver.Current.GetService<ITitleResolver>(); | |
| public class MyTitleResolver : ITitleResolver { | |
| // pass in whatever values you need | |
| // The FlushHead() method automatically copies over any ViewData/ViewBag state, accepts an optional title parameter as well an optional model parameter, if required. Pass it in here | |
| public string Resolve(IDictionary<string,object> values) { | |
| var title = ""; | |
| // Figure out the title based on the context | |
| return title; | |
| } | |
| } | |
| //Boooom goes the dynamite! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment