summaryrefslogtreecommitdiff
path: root/layouts/partials/blog-list.html
diff options
context:
space:
mode:
authorVidhu Kant Sharma <vidhukant@vidhukant.com>2023-08-27 01:36:12 +0530
committerVidhu Kant Sharma <vidhukant@vidhukant.com>2023-08-27 01:36:12 +0530
commit77d4a98a666ef6c2c18c10f2f2d62210f9eeb752 (patch)
tree11c75334b682009ff015a0fcd2e8eddc7eb4d315 /layouts/partials/blog-list.html
first commit
Diffstat (limited to 'layouts/partials/blog-list.html')
-rw-r--r--layouts/partials/blog-list.html16
1 files changed, 16 insertions, 0 deletions
diff --git a/layouts/partials/blog-list.html b/layouts/partials/blog-list.html
new file mode 100644
index 0000000..c05eb84
--- /dev/null
+++ b/layouts/partials/blog-list.html
@@ -0,0 +1,16 @@
+{{ range (union .Sections .Pages).ByDate.Reverse }}
+ <div class="blog-post-wrapper">
+ <a class="blog-post-anchor" href="{{ .RelPermalink }}">
+ <div class="blog-post">
+ <span class="date">
+ {{/* .Date.Format "2" }}{{ if in (slice 1 21 31) .Date.Day}}st{{ else if in (slice 2 22) .Date.Day}}nd{{ else if in (slice 3 23) .Date.Day}}rd{{ else }}th{{ end }} {{ .Date.Format "January" */}}
+ {{ .Date.Format "02" }} {{ .Date.Format "Jan" }}
+ </span>
+
+ <span class="title">
+ {{ .Title }}
+ </span>
+ </div>
+ </a>
+ </div>
+{{ end }}