Zustand with typescript
I honestly do not know what is wrong in here.
11 Replies
the types were weird but fixed it like this for me
lemme try it
okay.. @barry it worked
but another error came up
React is telling me now that setTime is not a function
did you do the types for it right
userConfigTime.actions.setTime should work
btw im not mad or something concerning your dm
but generally dont dm people without asking first
using it in another file?
its actions.setTime?
you dont need to set some actions object
its not like redux
sure
okay so assuming I don't use the actions: {} thing..
setTime(threshold) would still be right?
I exported the actions..so I get them directly
see!!
I exported it down here
ah yh then that should work
buttt..
this is what I see
idk lol