import { queries } from '@/lib/queries' import Link from 'next/link' import React from 'react' export default async function DashboardPage() { const events = await queries.fetchEvents() // console.log(events) return (

Dashboard

Your Events

{events.map((item) => (

ID: {item.id}

Name: {item.name}

Date: {item.date ? item.date.toISOString() : 'null'}

Location: {item.location ? item.location : 'null'}

Creator ID:{item.creatorId}

Created At:{item.createdAt.toISOString()}

))} See all events
) }