24 lines
615 B
Elixir
24 lines
615 B
Elixir
defmodule Website.BlogPage do
|
|
use Tableau.Page,
|
|
layout: Website.PageLayout,
|
|
permalink: "/blog",
|
|
title: "Blog"
|
|
|
|
use Phoenix.Component
|
|
|
|
def template(assigns) do
|
|
~H"""
|
|
<section>
|
|
<article :for={post <- @posts} class="mt-8">
|
|
Blog description goes here
|
|
<a class="underline text-base flex items-center justify-between" href={"blog/" <> post.permalink}>
|
|
<h3>
|
|
<time><%= post.date |> Calendar.strftime("%d.%b.%Y") %></time>
|
|
<%= post.title %>
|
|
</h3>
|
|
</a>
|
|
</article>
|
|
</section>
|
|
"""
|
|
end
|
|
end
|