#How to rename void imported from ahooks?

9 messages · Page 1 of 1 (latest)

void rampart
#

Is that possible to rename toggle for something else? I was trying toggle as test, but it seems that is not the proper way. I can't find any solutions in internet 😦

const [something, { toggle, set }] = useToggle(false);

https://ahooks.js.org/hooks/use-toggle/

wind bison
#

toggle: newName

#

try checking docs :/

void rampart
#

thanks 🙂

#

!resolved

wind bison
#

meh not really

#

and that's without "js" or "site:stackoverflow.com", although the former could probably be attributed to me using js quite a lot already lol