Open llr101 opened 3 months ago
I cannot update Badge action by state
below
const [isMuted, setIsMuted] = useState(false); useEffect(() => { setTimeout(() => setMuted(prev => !prev), 1000); }, []) return ( <Badge action={isMuted ? 'muted' : 'info'}> <BadgeText>test badge</Badge> </Badge> )
1.1.39
No response
Had the same issue trying to use state for updates. A workaround is to set a key prop that changes with state - forces a new component render.
Description
I cannot update Badge action by state
CodeSandbox/Snack link
below
Steps to reproduce
gluestack-ui Version
1.1.39
Platform
Other Platform
No response
Additional Information
No response