Skip to content

aiyun1010/useStateCallback

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

Add second parameter for useState , to resolve useState hook dose not accept a callback function

old code

const [count,setCount] = useState(0);
setCount(1)

now

const [count,setCount] = useStateX(0);
setCount(1,()=>{ ... })

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published