Building custom hooks in React is always a good idea if it helps you avoid repeating code!

Custom hooks make life easier for us when we have to build the functionality that can be stored inside a utility, spending time to come up with a great hook will save you lots of time in the future!