Introduction
Introduction about Primehooks package
Primehooks
Super lightweight, modern, and performant React hooks designed for real-world React apps, with first-class TypeScript, tree-shaking, and zero-runtime bloat. PrimeHooks focuses on correctness, ergonomics, and DX while staying framework-agnostic and bundler-friendly. PrimeHooks is built to be copy-paste friendly and production-minded: minimal API surface, strong typings, no peer surprises, and predictable behavior across browsers and SSR.
Why PrimeHooks?
- Lightweight - Minimal bundle size impact
- SSR Aware - safe on the server, reactive on the client.
- Tree Shakable - Dead code stays out of bundles.
- Typesafe - Full TypeScript support
- Tested - Comprehensive test coverage
- Well-documented - Clear examples and API references
Philosophy
Small, sharp APIs that do one thing well and remain composable. Stable identities by default to prevent unnecessary re-renders. Escape hatches where it counts, with both controlled and uncontrolled patterns. Zero dependencies, predictable internals, and consistent cleanup for observers, timers, and listeners.
Installation
Installing and using primehooks is super easy! Supports React 18+
npm install primehooksMaintainers
Contributors
Last updated on