react-utils - v1.0.31
    Preparing search index...
    • Custom hook for synchronizing theme preferences between cookies and application state

      Returns void

      Manages theme synchronization by:

      • Reading theme preferences from cookies on initial load
      • Applying theme settings to both state manager and DOM
      • Supporting both color mode (light/dark) and high contrast mode
      // Basic usage in component
      useThemeFromCookies();
      // With theme store access
      const { mode } = useThemeStore();
      useThemeFromCookies();
      • useThemeStore For the underlying theme state management
      • PaletteMode For available theme modes
      • parseCookies For cookie parsing utility