From 0f38aee374029213a47ef7c29bd164093fe63c85 Mon Sep 17 00:00:00 2001
From: Armand Philippot <git@armandphilippot.com>
Date: Wed, 15 Nov 2023 12:24:42 +0100
Subject: refactor(hooks): remove useSettings hook

It does not make sense to re-export an existing object through a hook.
On some pages both the hook and the object was imported...
It is better to use the CONFIG (previously settings) object directly
and by doing it we avoid potential errors because of conditional hooks.
---
 src/components/atoms/layout/time/time.test.tsx | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'src/components/atoms/layout/time/time.test.tsx')

diff --git a/src/components/atoms/layout/time/time.test.tsx b/src/components/atoms/layout/time/time.test.tsx
index 910285d..f3da8b5 100644
--- a/src/components/atoms/layout/time/time.test.tsx
+++ b/src/components/atoms/layout/time/time.test.tsx
@@ -1,6 +1,6 @@
 import { describe, expect, it } from '@jest/globals';
 import { render, screen as rtlScreen } from '../../../../../tests/utils';
-import { settings } from '../../../../utils/config';
+import { CONFIG } from '../../../../utils/config';
 import { Time } from './time';
 
 describe('Time', () => {
@@ -31,7 +31,7 @@ describe('Time', () => {
     expect(
       rtlScreen.getByText(new RegExp(`${date.getFullYear()}`))
     ).toHaveTextContent(
-      new Intl.DateTimeFormat(settings.locales.defaultLocale, {
+      new Intl.DateTimeFormat(CONFIG.locales.defaultLocale, {
         weekday: 'long',
       }).format(date)
     );
-- 
cgit v1.2.3

