wip add button and feed stuff

This commit is contained in:
john 2025-05-03 23:40:30 +02:00
parent 38d09a582c
commit 1c2d6d60a6
11 changed files with 211 additions and 46 deletions

View file

@ -5,17 +5,7 @@ interface PostsFeedProps {
posts: Post[]
}
export function PostsFeed({ posts }: PostsFeedProps) {
const formatDate = (date: Temporal.PlainDateTime) => {
return date.toLocaleString('en-US', {
year: 'numeric',
month: 'short',
day: 'numeric',
hour: '2-digit',
minute: '2-digit',
})
}
export default function PostsFeed({ posts }: PostsFeedProps) {
return (
<div className="flex flex-col gap-6 w-full">
{posts.map((post) => (
@ -36,3 +26,13 @@ export function PostsFeed({ posts }: PostsFeedProps) {
</div>
)
}
function formatDate(date: Temporal.PlainDateTime) {
return date.toLocaleString('en-US', {
year: 'numeric',
month: 'short',
day: 'numeric',
hour: '2-digit',
minute: '2-digit',
})
}