diff --git a/client/src/pages/TripPlannerPage.tsx b/client/src/pages/TripPlannerPage.tsx index a02263d..778c7da 100644 --- a/client/src/pages/TripPlannerPage.tsx +++ b/client/src/pages/TripPlannerPage.tsx @@ -118,7 +118,7 @@ export default function TripPlannerPage(): React.ReactElement | null { const [mapCategoryFilter, setMapCategoryFilter] = useState('') - const mapPlaces = useCallback(() => { + const mapPlaces = useMemo(() => { return places.filter(p => { if (!p.lat || !p.lng) return false if (mapCategoryFilter && String(p.category_id) !== String(mapCategoryFilter)) return false @@ -376,7 +376,7 @@ export default function TripPlannerPage(): React.ReactElement | null { {activeTab === 'plan' && (