From f8abd467d40ce9c98d0b10d436181fc2d9b69986 Mon Sep 17 00:00:00 2001
From: trisusilo48 <tri.susilo@altama.co.id>
Date: Wed, 2 Oct 2024 14:37:13 +0700
Subject: oprimize code

---
 src/pages/index.jsx | 16 +++++++---------
 1 file changed, 7 insertions(+), 9 deletions(-)

(limited to 'src/pages/index.jsx')

diff --git a/src/pages/index.jsx b/src/pages/index.jsx
index 6077c192..ac925b4e 100644
--- a/src/pages/index.jsx
+++ b/src/pages/index.jsx
@@ -1,21 +1,19 @@
-import dynamic from 'next/dynamic';
-import { useEffect, useRef, useState } from 'react';
 import { HeroBannerSkeleton } from '@/components/skeleton/BannerSkeleton';
 import { PopularProductSkeleton } from '@/components/skeleton/PopularProductSkeleton';
+import odooApi from '@/core/api/odooApi';
 import Seo from '@/core/components/Seo';
 import DelayRender from '@/core/components/elements/DelayRender/DelayRender';
 import DesktopView from '@/core/components/views/DesktopView';
 import MobileView from '@/core/components/views/MobileView';
 import { FlashSaleSkeleton } from '@/lib/flashSale/skeleton/FlashSaleSkeleton';
-import PreferredBrandSkeleton from '@/lib/home/components/Skeleton/PreferredBrandSkeleton';
 import BannerPromoSkeleton from '@/lib/home/components/Skeleton/BannerPromoSkeleton';
-import PromotinProgram from '@/lib/promotinProgram/components/HomePage';
+import PreferredBrandSkeleton from '@/lib/home/components/Skeleton/PreferredBrandSkeleton';
+import dynamic from 'next/dynamic';
+import { useEffect, useRef, useState } from 'react';
+import { getAuth } from '~/libs/auth';
 import PagePopupIformation from '~/modules/popup-information'; // need change to dynamic and ssr : false
 import CategoryPilihan from '../lib/home/components/CategoryPilihan';
-import odooApi from '@/core/api/odooApi';
-import { getAuth } from '~/libs/auth';
 // import { getAuth } from '~/libs/auth';
-import useProductDetail from '~/modules/product-detail/stores/useProductDetail';
 
 const BasicLayout = dynamic(() =>
   import('@/core/components/layouts/BasicLayout'),{ssr: false}
@@ -55,14 +53,14 @@ const ProgramPromotion = dynamic(() =>
 );
 
 const BannerSection = dynamic(() =>
-  import('@/lib/home/components/BannerSection'), {ssr: false}
+  import('@/lib/home/components/BannerSection')
 );  
 const CategoryHomeId = dynamic(() =>
   import('@/lib/home/components/CategoryHomeId'), {ssr: false}
 );
 
 const CategoryDynamic = dynamic(() =>
-  import('@/lib/home/components/CategoryDynamic'), {ssr: false}
+  import('@/lib/home/components/CategoryDynamic'), {ssr : false}
 );
 
 const CategoryDynamicMobile = dynamic(() =>
-- 
cgit v1.2.3

