diff --git a/cookie-manager/react/package.json b/cookie-manager/react/package.json index e795423..de9070d 100644 --- a/cookie-manager/react/package.json +++ b/cookie-manager/react/package.json @@ -1,6 +1,6 @@ { "name": "@boxfish-studio/react-cookie-manager", - "version": "1.0.0", + "version": "1.0.1", "author": "Boxfish Studio ", "license": "Apache-2.0", "repository": "github:boxfish-studio/cookie-manager", diff --git a/cookie-manager/react/src/lib/app/hooks.tsx b/cookie-manager/react/src/lib/app/hooks.tsx index bd22549..8334941 100644 --- a/cookie-manager/react/src/lib/app/hooks.tsx +++ b/cookie-manager/react/src/lib/app/hooks.tsx @@ -21,7 +21,7 @@ export function useManageServices(): { configuredServices.value, servicesInitialized.setValue ) - }, [necessaryCookies, configuredServices]) + }, [configuredServices, servicesInitialized]) const stopServices = useCallback(() => { stopCoreServices( @@ -29,7 +29,7 @@ export function useManageServices(): { removeUnnecessaryCookies, servicesInitialized.setValue ) - }, [configuredServices, necessaryCookies]) + }, [configuredServices, servicesInitialized, removeUnnecessaryCookies]) return { initializeServices: initServices, stopServices, removeUnnecessaryCookies } } diff --git a/cookie-manager/react/src/lib/components/CookieManager/CookieManager.tsx b/cookie-manager/react/src/lib/components/CookieManager/CookieManager.tsx index 60571b6..70704b3 100644 --- a/cookie-manager/react/src/lib/components/CookieManager/CookieManager.tsx +++ b/cookie-manager/react/src/lib/components/CookieManager/CookieManager.tsx @@ -36,7 +36,7 @@ export function CookieManager({ configuration }: CookieManagerProps): React.JSX. } else { showCookieDisclaimer.setValue(true) } - }, [necessaryCookies.value]) + }, [necessaryCookies.value, initializeServices]) function handleSubmitNecessaryCookies(value: 'true' | 'false'): void { setNecessaryCookies( diff --git a/demo/nextjs/app/page.tsx b/demo/nextjs/app/page.tsx index 233f0e2..ebae77b 100644 --- a/demo/nextjs/app/page.tsx +++ b/demo/nextjs/app/page.tsx @@ -1,95 +1,9 @@ -import Image from 'next/image' import styles from './page.module.css' export default function Home(): React.JSX.Element { return (
-
- Next.js logo -
    -
  1. - Get started by editing app/page.tsx. -
  2. -
  3. Save and see your changes instantly.
  4. -
- -
- - Vercel logomark - Deploy now - - - Read our docs - -
-
- +
NextJS Demo
) }