rules of hooks question - Theo's Typesafe Cult