aboutsummaryrefslogtreecommitdiff
path: root/templates/article.ejs
diff options
context:
space:
mode:
authorFuwn <[email protected]>2020-11-06 18:24:26 -0800
committerFuwn <[email protected]>2020-11-06 18:24:26 -0800
commit9cdce4254700691301608c6f1d3081950023cc4f (patch)
tree9d24529acc19b354f80cb2d610aa1e7686f4d530 /templates/article.ejs
downloadblog-9cdce4254700691301608c6f1d3081950023cc4f.tar.xz
blog-9cdce4254700691301608c6f1d3081950023cc4f.zip
repo: initial :star:
Diffstat (limited to 'templates/article.ejs')
-rw-r--r--templates/article.ejs39
1 files changed, 39 insertions, 0 deletions
diff --git a/templates/article.ejs b/templates/article.ejs
new file mode 100644
index 0000000..df12d51
--- /dev/null
+++ b/templates/article.ejs
@@ -0,0 +1,39 @@
+<article class="article">
+ <header class="title">
+ <% if (!timeless && hidden) { %>
+ <p>
+ <strong>Note:</strong>
+ This article is hidden and is only available to those with a link.
+ </p>
+ <% } %>
+
+ <% if (!timeless && date) { %>
+ <div class="date">
+ <%= date %>
+ </div>
+ <% } %>
+ <h1><%= title %></h1>
+
+ <% if (tags.length) { %>
+ <div>
+ <span class="posted-in">Posted in: </span>
+ <span>
+ <% tags.forEach(function(tag, i) { %>
+ <a href="/tags/<%= tag %>"><%= tag %></a><% if (i !== tags.length - 1) { %>, <% } %>
+ <% }) %>
+ </span>
+ </div>
+ <% } %>
+ </header>
+
+ <section class="content">
+ <%- body %>
+ </section>
+
+ <footer class="more details">
+ --
+ <br><br>
+ <!-- <a target="_blank" rel="noopener" href="<%= tweetUrl %>" class="tweet">tweet this</a> -->
+ <a href="/">&laquo; back to home</a>
+ </footer>
+</article>