typescript usereducer example, thor financial god mode