Skip to content

Instantly share code, notes, and snippets.

View philipdanielhayton's full-sized avatar

Philip Daniel Hayton philipdanielhayton

View GitHub Profile
@philipdanielhayton
philipdanielhayton / tailwind.config.js
Created September 5, 2021 11:12
Tailwind JIT Safelist String Generator
module.exports = {
purge: {
content: [
"..."
],
safelist: [
...createSafeListString({
rules: ["mt", "mb", "pt", "pb"],
values: [1, 2, 3, 4, 6, 8, 12, 16, 24],
responsive: [null, "xs", "sm", "md", "lg"],
@philipdanielhayton
philipdanielhayton / XmlSitemap.cshtml
Created August 3, 2016 19:32
Umbraco Xml Sitemap using Razor
@inherits Umbraco.Web.Mvc.UmbracoTemplatePage
@{
Layout = null;
var root = Umbraco.TypedContentSingleAtXPath("//homePage");
umbraco.library.ChangeContentType("text/xml");
}
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
@renderUrl(root)
</urlset>
@helper renderUrl(IPublishedContent node)