-export const formatDate = (isoDate: string) => {
- const date = new Date(isoDate);
- const text = date.toLocaleString();
- return text === 'Invalid Date' ? "" : text;
+import { PropertyValue } from "~/models/search-bar";
+
+export const formatDate = (isoDate?: string | null) => {
+ if (isoDate) {
+ const date = new Date(isoDate);
+ const text = date.toLocaleString();
+ return text === 'Invalid Date' ? "(none)" : text;
+ }
+ return "(none)";