private static string GetTemplatesHtml()
{
const string Key = "BlueCollar.Dashboard.Index.Templates";
string templates = HttpRuntime.Cache[Key] as string;
if (string.IsNullOrEmpty(templates))
{
templates = StaticFile.GetContentsAsString("BlueCollar.Dashboard.Static.templates.html");
HttpRuntime.Cache.Add(
Key,
templates,
null,
Cache.NoAbsoluteExpiration,
Cache.NoSlidingExpiration,
CacheItemPriority.Normal,
null);
}
return templates;
}