SSE Hooks

Introduction

Welcome to the sse-hooks documentation.

sse-hooks is a comprehensive library of custom hooks made for React and Next.js to build powerful & responsive applications with less boilerplate.

Explore our most popular hooks available in the collection:

useAudioRecorder

Comprehensive audio recording with real-time analysis and Web Audio API support.

useFetch

A wrapper around the native Fetch API with built-in state management and caching.

useLocalStorage

Persist state to local storage with automatic serialization and synchronization.

useIntersectionObserver

Track when an element enters or leaves the viewport using the Intersection Observer API.

useClickAway

Detect clicks outside of a specific element (great for modals and dropdowns).

useDarkMode

Easily manage dark and light themes with preference detection.

Key Features

This package provides a robust set of utilities designed to enhance your development workflow:

  • Built for React & Next.js: Optimized for modern React lifecycles and Server-Side Rendering (SSR).
  • Fully Type-Safe: Written in TypeScript with complete type inference and definitions.
  • Tree-Shakeable Exports: Import only the hooks you need to keep your bundle size minimal.
  • SSR Compatible: Safely handles hydration and server-side execution without window errors.
  • Zero Dependencies: Keeps your project lightweight and reduces security risks.
  • Browser Standard APIs: Wrappers around IntersectionObserver, ResizeObserver, localStorage, and more.
  • Extensive Collection: Over 30+ hooks covering Sensors, UI, State, and Network utilities.
Built with Love • © 2026