add article display

This commit is contained in:
b1ek 2023-02-27 16:34:08 +10:00
parent 78cb14bbd2
commit 169a8a2405
Signed by: blek
GPG Key ID: 14546221E3595D0C
2 changed files with 9 additions and 4 deletions

View File

@ -9,12 +9,17 @@ async function handler(req, res) {
where: { hidden: false }
});
let articles = await Sequelize.Article.findAll({
limit: 5
});
res.send(
await Helpers.ViewLoader.load(
'main.pug',
{
current_route: '/',
gb_entries
gb_entries,
articles
}
)
);

View File

@ -35,11 +35,11 @@ block content
td(width='50%' style='border-left:1px solid #c2c4c2;border-right:1px solid #c2c4c2;padding:0 1%')
h3 Blog
ul
each i in [0,0,0,0,0]
each article in articles
li(style='font-size:16pt')
| entry
h5= article.title
ul
li data
li= article.shortText
td(width='20%')
h4 Links