I'm currently working on a scenario where I need to implement logic for checking or unchecking a checkbox in React Native. If the checkbox is checked, I want to print one string, and if it's unchecked, I want to print something else. How can I achieve this in React Native?
Below is my code snippet:
checked={this.state.checked}
onPress={() => {
this.actiondone();
}}
actiondone(){
//Need to determine if checkbox is checked or not and perform actions accordingly
}