From fe7254f7a7b7c8b95824f2d6ce2ee56709ba019d Mon Sep 17 00:00:00 2001 From: Stanisław Zagórowski Date: Sun, 14 Jan 2024 16:21:57 +0100 Subject: luax: stuff --- luax/pages/blog.luax | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 luax/pages/blog.luax (limited to 'luax/pages/blog.luax') diff --git a/luax/pages/blog.luax b/luax/pages/blog.luax new file mode 100644 index 0000000..26f9fc0 --- /dev/null +++ b/luax/pages/blog.luax @@ -0,0 +1,28 @@ +local blogposts = require('blog.posts') + +return function() + local blogpost_html = {} + for _, post in ipairs(blogposts) do + blogpost_html[#blogpost_html + 1] = +
+
+ {$ post.title $} +
+ +
+ {$ post.description $} +
+
+ end + return +
+
+ Blog +
+
+ {$ blogpost_html $} +
+
+end -- cgit v1.3.1