diff --git a/components/expenses/Card.vue b/components/expenses/Card.client.vue
similarity index 93%
rename from components/expenses/Card.vue
rename to components/expenses/Card.client.vue
index 6cd35f1..4435022 100644
--- a/components/expenses/Card.vue
+++ b/components/expenses/Card.client.vue
@@ -80,12 +80,14 @@ const expenseFormStore = useExpenseFormStore();
Paid by {{ author?.name }}
- {{
- new Date(expense.date).toLocaleDateString(undefined, {
- timeZone: "UTC",
- dateStyle: "long",
- })
- }}
+
+ {{
+ new Date(expense.date).toLocaleDateString(undefined, {
+ timeZone: "UTC",
+ dateStyle: "long",
+ })
+ }}
+
diff --git a/components/expenses/View.vue b/components/expenses/View.client.vue
similarity index 100%
rename from components/expenses/View.vue
rename to components/expenses/View.client.vue
diff --git a/components/new-expense/Infos.vue b/components/new-expense/Infos.vue
index 60bbdef..05f541c 100644
--- a/components/new-expense/Infos.vue
+++ b/components/new-expense/Infos.vue
@@ -1,5 +1,5 @@
diff --git a/utils/dinero.ts b/utils/dinero.ts
index 03fc73e..d8b56b9 100644
--- a/utils/dinero.ts
+++ b/utils/dinero.ts
@@ -25,12 +25,6 @@ export function toString(amount: Dinero): string {
);
}
-export const currencyRecord: Record<
- Currency["code"],
- Currency
-> = {};
-for (const currency of Object.values(currencies)) {
- if (currency.code) {
- currencyRecord[currency.code] = currency;
- }
-}
+export const currencyRecord = Object.fromEntries(
+ Object.values(currencies).map((currency) => [currency.code, currency])
+);