usehooks-ts
TypeScript icon, indicating that this package has built-in type declarations

3.1.0 • Public • Published

usehooks-ts banner


usehooks-ts

React hook library, ready to use, written in Typescript.

Contributor Covenant NPM Downloads NPM Downloads License npm bundle size npm All Contributors


npm i usehooks-ts

Created by Julien Caron and maintained with ❤️ by an amazing team of developers.

💫 Introduction

useHooks(🔥).ts is a React hooks library, written in Typescript and easy to use. It provides a set of hooks that enables you to build your React applications faster. The hooks are built upon the principles of DRY (Don't Repeat Yourself). There are hooks for most common use cases you might need.

The library is designed to be as minimal as possible. It is fully tree-shakable (using the ESM version), meaning that you only import the hooks you need, and the rest will be removed from your bundle making the cost of using this library negligible. Most hooks are extensively tested and are being used in production environments.

Usage example

import { useLocalStorage } from 'usehooks-ts'

function Component() {
  const [value, setValue] = useLocalStorage('my-localStorage-key', 0)

  // ...
}

🪝 Available Hooks

💚 Backers

Big thanks go to all our backers! [Become a backer]

Sentry
Sentry
KATT
KATT
Adhi Ravishankar
Adhi Ravishankar
great-work-told-is
great-work-told-is

✨ Contributors

Big thanks go to all our contributors! [Become a contributor]

Julien
Julien

🖋 💻 🎨 🤔
a777med
a777med

💻
Nguyen Tien Dat
Nguyen Tien Dat

💻
Elias Cohenca
Elias Cohenca

🖋
João Deroldo
João Deroldo

🐛 💻
Nishit
Nishit

💻
Jon Koops
Jon Koops

💻
LoneRifle
LoneRifle

💻
Viktor
Viktor

🤔 🐛
Bruno Clermont
Bruno Clermont

💬
yoannesbourg
yoannesbourg

🤔
Strange2x
Strange2x

🤔
Jason Pickens
Jason Pickens

🐛
Sel-Vin Kuik
Sel-Vin Kuik

🐛
isaac
isaac

🐛
Bruno RZN
Bruno RZN

💻 👀
Nathan Manceaux-Panot
Nathan Manceaux-Panot

💻 👀
Dien Vu
Dien Vu

🤔
Oleg Kusov
Oleg Kusov

🤔
Matthew Guy
Matthew Guy

🤔
andrewbihl
andrewbihl

🐛
lancepollard
lancepollard

🐛
Mukul Bansal
Mukul Bansal

🐛
Jean-Luc Mongrain sur la Brosse
Jean-Luc Mongrain sur la Brosse

💻 🤔
Nic
Nic

🖋
Dan Wood
Dan Wood

💻
jo wendenbuerger
jo wendenbuerger

🐛
Andrew Nosenko
Andrew Nosenko

🐛
CharlieJhonSmith
CharlieJhonSmith

💻
Sullivan SENECHAL
Sullivan SENECHAL

🤔 🐛 💻
Jason Long
Jason Long

🐛
kxm766
kxm766

🐛
Quentin
Quentin

💻 🤔 🖋
Daniel Lazar
Daniel Lazar

💻 🐛
Mark Terrel
Mark Terrel

🐛 💻
Andreas Herd
Andreas Herd

🐛
Sonjoy Datta
Sonjoy Datta

💻
Ilya Belsky
Ilya Belsky

🐛
James Barrett
James Barrett

💻
AbbalYouness
AbbalYouness

💻
didriklind
didriklind

💻 ⚠️
hexp1989
hexp1989

💻
Alvaro Serrano
Alvaro Serrano

🖋
Egehan Dülger
Egehan Dülger

💻
PabloLION
PabloLION

🐛 💻
David Sanchez
David Sanchez

🐛
Ajay Raja
Ajay Raja

🐛
Andy Merskin
Andy Merskin

🤔
Avirup Ghosh
Avirup Ghosh

💻 🐛
Sanne Wintrén
Sanne Wintrén

🐛
Alessandro
Alessandro

🐛
Andrey Tatarenko
Andrey Tatarenko

🐛
Anton Rusak
Anton Rusak

🐛
Mahmood Bagheri
Mahmood Bagheri

💻
Anver Sadutt
Anver Sadutt

🖋
Bogdan Ailincai
Bogdan Ailincai

💻
Simeon Griggs
Simeon Griggs

🐛
Kepro
Kepro

🐛
Jake Lippert
Jake Lippert

🐛
Tu Nguyen Anh
Tu Nguyen Anh

🐛 💻
Luke Shiels
Luke Shiels

🐛
Sergei Kolyago
Sergei Kolyago

🤔
Adham Akmal Azmi
Adham Akmal Azmi

🐛
Alek Kowalczyk
Alek Kowalczyk

🐛
Sean Callahan
Sean Callahan

🐛
Joshua Bean
Joshua Bean

💻 🐛
Tim Zhao
Tim Zhao

🐛
Patrick
Patrick

🐛
Bryce Dorn
Bryce Dorn

💻
angusd3v
angusd3v

💻
Davide Di Simone
Davide Di Simone

🐛
Jack Herrington
Jack Herrington

🐛
Avi Sharvit
Avi Sharvit

💻 🐛
Nicolae Maties
Nicolae Maties

🐛
Shardul Aeer
Shardul Aeer

🐛
Herlon Aguiar
Herlon Aguiar

🐛
Alexis Oney
Alexis Oney

🖋
curtvict
curtvict

💻
Josué Cortina
Josué Cortina

🖋
Alex / KATT
Alex / KATT

💻
Mourad EL CADI
Mourad EL CADI

💻 🐛
James Hulena
James Hulena

🐛
Matthew Hailwood
Matthew Hailwood

💻 👀
Michael Norrie
Michael Norrie

🐛
Valentin Politov
Valentin Politov

💻
Marnus Weststrate
Marnus Weststrate

💻
mancuoj
mancuoj

🖋
Chat Sumlin
Chat Sumlin

💻
Owen Haupt
Owen Haupt

🐛 🖋
ubarbaxor
ubarbaxor

💻
Michael Mior
Michael Mior

🐛 🖋
Pierre
Pierre

💻
Harry B
Harry B

🐛
Valerie
Valerie

🐛 💻
Steven Vachon
Steven Vachon

💻
Sean Kirby
Sean Kirby

⚠️ 💻
Alecsander Farias
Alecsander Farias

💻
Rahul Mishra
Rahul Mishra

💻 👀 🖋
Bryant Smith
Bryant Smith

💻 🐛
Rob Hannay
Rob Hannay

💻
Hooriza
Hooriza

💻 🐛
ShanSenanayake
ShanSenanayake

💻
Philip Ghering
Philip Ghering

💻
Ladislas Dellinger
Ladislas Dellinger

💻
Haff
Haff

💻
Lisandro
Lisandro

💻
Amir hossein rezaei
Amir hossein rezaei

💻
Nicolas Macian
Nicolas Macian

🐛 💻
Nate Forsyth
Nate Forsyth

💻
satelllte
satelllte

💻 🐛
Federico Panico
Federico Panico

💻
William Pei Yuan
William Pei Yuan

💻
Mihai
Mihai

💻 🐛
Habib Ogunsola
Habib Ogunsola

🖋
Ash Furrow
Ash Furrow

💻
Daniel Turuș
Daniel Turuș

💻
Rahul Chaudhary
Rahul Chaudhary

🖋 🐛
Joshua Ojoawo
Joshua Ojoawo

🤔 🐛
Jack
Jack

💻
Jon Linkens
Jon Linkens

💻 🐛
Jeongjin Oh
Jeongjin Oh

🐛
Tianning Li
Tianning Li

💻
Lars Artmann
Lars Artmann

🖋
KBobovskiy
KBobovskiy

💻
✨ Kathryn Gonzalez ✨
✨ Kathryn Gonzalez ✨

🖋
Yaroslav Chapelskyi
Yaroslav Chapelskyi

🖋
Samuel Van Erps
Samuel Van Erps

👀
ojolowoblue
ojolowoblue

🖋
Andrii Kostenko
Andrii Kostenko

💻
Akeem Allen
Akeem Allen

💻 🐛
trongbinhnguyen
trongbinhnguyen

🖋
Aniruddha Sil
Aniruddha Sil

💻
박찬혁
박찬혁

👀
Anish
Anish

💻
Hugo Hutri
Hugo Hutri

🖋
Balz Guenat
Balz Guenat

💻
OtterGeorge
OtterGeorge

💻
Samay Sagar
Samay Sagar

🖋
Pedro Lisboa
Pedro Lisboa

🐛
Henrique Malheiros
Henrique Malheiros

🐛
Kevin Newman
Kevin Newman

💻
a503189
a503189

🖋
Mourad EL CADI
Mourad EL CADI

💻
Pedro Henrique Lopes
Pedro Henrique Lopes

💻
Danbi Lee
Danbi Lee

💻
Connor Jennings
Connor Jennings

💻
Lucas Gomes
Lucas Gomes

🐛 💻
Martin Zagora
Martin Zagora

💻
KvD
KvD

💻
Alex
Alex

💻
Kacey Cleveland
Kacey Cleveland

👀
Avirup Ghosh
Avirup Ghosh

🐛
yabbal
yabbal

💻
Craig Patik
Craig Patik

🐛
Soldeplata Saketos Candela
Soldeplata Saketos Candela

💻
TENDOUZHI
TENDOUZHI

🐛
Marcin Wachulski
Marcin Wachulski

🐛
Salman Fazal
Salman Fazal

🐛
shrugs
shrugs

🐛
hyodori
hyodori

🐛
Eleazar “E” Ramos
Eleazar “E” Ramos

🐛
retnag
retnag

🐛
J young Lee
J young Lee

🐛
Filip Weiss
Filip Weiss

🐛
Marius Gundersen
Marius Gundersen

🐛
Syed Aman Ali
Syed Aman Ali

🐛
Axel Ingadi
Axel Ingadi

🐛
AndyP
AndyP

🐛
ishanVaghasiya
ishanVaghasiya

🐛
Nico Martinucci
Nico Martinucci

🐛
Shiv Bhonde | shivbhonde.eth
Shiv Bhonde | shivbhonde.eth

🐛
fritzmonkey
fritzmonkey

🐛
Rodrigo Mesquita
Rodrigo Mesquita

🐛
Moshe Simantov
Moshe Simantov

🐛
Beka
Beka

🐛
Abdallah Alkaser
Abdallah Alkaser

🐛 💻
Carl Smith
Carl Smith

🐛
Orlando Groppo
Orlando Groppo

🐛
Martijn Saly
Martijn Saly

🐛
Quinn Shanahan
Quinn Shanahan

🐛
Antoine Kingue
Antoine Kingue

🐛
Žan Žlender
Žan Žlender

🐛
Sebastian Dominguez
Sebastian Dominguez

🐛
James Cowan
James Cowan

🐛
Bayram Ali Basgul
Bayram Ali Basgul

🐛
Wyatt Castaneda
Wyatt Castaneda

🐛
Tim Neville
Tim Neville

🐛
Thomas Pigarelli
Thomas Pigarelli

🐛
James Herdman
James Herdman

🐛
Grzegorz Pociejewski
Grzegorz Pociejewski

🐛
René Verheij
René Verheij

🐛
PatrykKuniczak
PatrykKuniczak

🐛
Paolo Božac
Paolo Božac

🐛
Rein
Rein

🐛
FloorianB
FloorianB

🐛
Xuan Hung
Xuan Hung

🐛
Monawwar Abdullah
Monawwar Abdullah

🐛
Haroldo de Oliveira Pinheiro
Haroldo de Oliveira Pinheiro

🐛
Tamjid Ahmed
Tamjid Ahmed

🐛
jv-lopez
jv-lopez

🐛
Callum Macrae
Callum Macrae

🐛
bywater529
bywater529

🐛
Kevin He
Kevin He

🐛
FredericoGauz
FredericoGauz

🐛
Jonathan "JonLem" Lemos
Jonathan "JonLem" Lemos

🐛
Xegulon
Xegulon

🐛
Tom Smedley
Tom Smedley

🐛
lightbluepoppy
lightbluepoppy

🐛
Derek Oware
Derek Oware

🐛
Lance Gliser
Lance Gliser

🐛
J. Lewis
J. Lewis

🐛
Yair
Yair

🐛
Nishchit
Nishchit

🐛
Devofy
Devofy

🐛
Josh Guyette
Josh Guyette

🐛
Dora Li
Dora Li

🐛
Kristian Gerardsson
Kristian Gerardsson

🐛
James Powell
James Powell

🐛
Boaz Poolman
Boaz Poolman

🐛
roker15
roker15

🐛
Fadhil Ahmad
Fadhil Ahmad

🐛
Chandler-Zhu
Chandler-Zhu

🐛
Nghi Nguyen
Nghi Nguyen

🐛
Shravan Sunder
Shravan Sunder

🐛
Johannes5
Johannes5

🐛
sebahhpeya
sebahhpeya

🐛
Or Nakash
Or Nakash

🐛
Erez Makavy
Erez Makavy

🐛
Andy Merskin
Andy Merskin

🐛
ChainAlert Bot
ChainAlert Bot

🐛
Taylor Morgan
Taylor Morgan

🐛
wisdomabioye
wisdomabioye

🐛
Samuel Quiñones
Samuel Quiñones

🤔
Manuel
Manuel

💻 🐛
Yurii Rybak
Yurii Rybak

🐛
Yury Demin
Yury Demin

🐛 💻
Jon Tewksbury
Jon Tewksbury

💻 🐛
Novac Denis
Novac Denis

💻 🐛
kyrylo-soulandwolf
kyrylo-soulandwolf

💻 🐛
Miguel Isidoro
Miguel Isidoro

💻
Yuriy Gromchenko
Yuriy Gromchenko

💻
Jacob Hummer
Jacob Hummer

🤔
Kyrylo Melnychuk
Kyrylo Melnychuk

🖋 💻
Luma
Luma

💻
Eliya Cohen
Eliya Cohen

💻
Igor Sukharev
Igor Sukharev

🐛
pookmish
pookmish

🤔
metav-drimz
metav-drimz

🤔
luckrnx09
luckrnx09

💻
Hubert Kuczmierczyk
Hubert Kuczmierczyk

🤔 👀
dandubya
dandubya

📖
Darwish
Darwish

💻
Jonathan Raoult
Jonathan Raoult

🐛 👀

This project follows the all-contributors specification (emoji key). Contributions of any kind welcome!

💞 Donate

If you find this piece of software helpful, please consider a donation. Any amount is greatly appreciated.

GitHub Sponsors Paypal Stripe Buy me a coffee

BTC: bc1qwys40tnd0lxf9lr9l0t6xc63dpxyucj4x4nay0

ETH: 0x36a85155a8300754C56395D5af24553FB18915D6

📝 License

This project is MIT licensed.

Readme

Keywords

Package Sidebar

Install

npm i usehooks-ts

Weekly Downloads

737,007

Version

3.1.0

License

MIT

Unpacked Size

251 kB

Total Files

7

Last publish

Collaborators

  • junscuzzy