update
This commit is contained in:
4
main.ts
4
main.ts
@@ -35,7 +35,7 @@ async function getBlogEntries() {
|
||||
title: '',
|
||||
createdAt: '',
|
||||
updatedAt: '',
|
||||
teaser: `${ dom.querySelector('article').textContent.slice(0, 128) }...`,
|
||||
teaser: `${ dom.querySelector('article')?.textContent.slice(0, 256).trimStart().trimEnd() }...`,
|
||||
};
|
||||
const metaTags = dom.querySelectorAll('meta') as unknown as NodeListOf<HTMLMetaElement>;
|
||||
for (const metaTag of metaTags) {
|
||||
@@ -88,7 +88,7 @@ async function rss() {
|
||||
<link>${ HOST }/blog/${ article.slug }</link>
|
||||
<pubDate>${ new Date(article.createdAt).toUTCString() }</pubDate>
|
||||
<author>Daniel Ledda</author>
|
||||
<description>${ article.content }</description>
|
||||
<description>${ article.teaser }</description>
|
||||
<guid>${ article.guid }</guid>
|
||||
</item>
|
||||
`).join('')}
|
||||
|
||||
Reference in New Issue
Block a user