react-native-switch icon indicating copy to clipboard operation
react-native-switch copied to clipboard

activeText is showing instead of the text we pass

Open jamesawer3 opened this issue 5 years ago • 4 comments

Installed this npm using npm install --save react-native-switch. In my switch.js code was wrong. Change

            {renderActiveText && (
              <Text style={[styles.text, styles.paddingRight, activeTextStyle]}>
                activeText
              </Text>
            )}

to

            {renderActiveText && (
              <Text style={[styles.text, styles.paddingRight, activeTextStyle]}>
                {activeText}
              </Text>
            )}

in Switch.js

jamesawer3 avatar Nov 07 '19 07:11 jamesawer3

I have the same Issue

mzparacha avatar Nov 07 '19 17:11 mzparacha

I have changed the code in node_modules/react-native-switch/lib/Switch.js as I mentioned and it's working fine

jamesawer3 avatar Nov 08 '19 05:11 jamesawer3

Please use GitHub version instead of NPM and confirm that this issue is still relevant. Thanks.

shahen94 avatar Nov 10 '19 07:11 shahen94

Can this not be updated on npm?

hmust92 avatar Jan 19 '20 22:01 hmust92