shahen94 / react-native-switch

Customisable switch component for RN
MIT License
296 stars 172 forks source link

disabled in componentDidUpdate will stop re-render #77

Open chj-damon opened 4 years ago

chj-damon commented 4 years ago

I'm using Switch in some detail screen, so I don't want user to enable it so I disabled it. But I found out that Switch will remain false. I remove disabled property then it works fine. So I think that's the reason.

shahen94 commented 4 years ago

Yes - If Switch is disabled - you can't change it's value, is this the issue ?

chj-damon commented 4 years ago

@shahen94 I mean it should be true if I set value is true. But actually it remains false even though the value is true, no matter I disable it or not.