package components import ( "context" "fmt" ) templ NotificationsPage(ctx context.Context, data NotificationsData) { @LayoutWithContext("Notifications", ctx) {

Notifications

if len(data.Notifications) == 0 {

No notifications

You don't have any notifications yet.

} else {
for _, notification := range data.Notifications {

{ notification.Title }

{ notification.Message }

{ FormatNotificationTime(notification.CreatedAt) } if !notification.IsRead { }
}
}
} }