Small fix to blog sorting order (now first = newest, last = oldest)

This commit is contained in:
itzMiney committed 2025-01-06 01:04:10 +01:00
1 parent 2597f7b5b2
commit a64c180502
1 file changed
+1 -1
+1 -1
View File
@@ -6,7 +6,7 @@
</div>
<div class="blog-container">
<div *ngIf="articles$ | async as articles; else noArticles">
<div *ngFor="let article of articles" (click)="navigateToArticle(article.slug)" class="article-card">
<div *ngFor="let article of articles.slice().reverse()" (click)="navigateToArticle(article.slug)" class="article-card">
<h2>{{ (article.title | slice:0:45) + (article.title.length > 40 ? '...' : '')}}</h2>
<p>{{ (article.content | slice:0:80) + (article.content.length > 80 ? '...' : '')}}</p>
<p><small>By {{ article.authorName }} | {{ article.createdAt | date: 'dd/MM/yy, HH:mm' }}</small></p>