Skip to content

Repository files navigation

@twigaeng/react-hooks

A collection of tiny but useful react hooks

NPMJavaScript Style Guide

Install

npm install --save @twigaeng/react-hooks

Usage

importReactfrom'react'import{useSalesDays}from'@twigaeng/react-hooks/'constApp=()=>{constdate=newDate();consttoday=date.getDay();consttomorrow=today+1;constisTodayASalesDay=useSalesDays([today])constisTomorrowASalesDay=useSalesDays([tomorrow])return(<div><p>Is today a sales days? {isTodayASalesDay.toString()}</p><p>Is tomorrow a sales days? {isTomorrowASalesDay.toString()}</p></div>)}exportdefaultApp

License

MIT © joeynimu


This hook is created using create-react-hook.

About

A collection tiny of React hooks

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages