Exemplo n.º 1
0
        private static string GetReleasePath(string path, string fileExt)
        {
            var revPath = GetMinifyPath(path, fileExt);

            if (!AppsHelper.IsDebug)
            {
                var revNumber = AppsHelper.GetRevNumber();
                revPath += "?rev=" + revNumber;
            }

            return(revPath);
        }
Exemplo n.º 2
0
        public static MvcHtmlString Style(this HtmlHelper helper, string[] asset)
        {
            var tpl = "";

            asset.ToList().ForEach(e =>
            {
                var path = AppsHelper.GetPath(e);
                var url  = GetReleasePath(path, "css");

                var style = $"<link rel=\"stylesheet\" href=\"{url}\"/>";
                tpl      += style;
            });

            return(MvcHtmlString.Create(tpl));
        }