import PropertyCard from '@/components/PropertyCard'; import Property from '@/models/Property'; import connectDB from '@/config/database'; const PropertiesPage = async () => { await connectDB(); const properties = await Property.find({}).lean(); return (
{properties.length === 0 ? (

No properties found

) : (
{properties.map((property, index) => ( ))}
)}
); }; export default PropertiesPage;