Sorry if the heading is misleading. I can't seem to find a suitable title. I have a two classes.
****************Form.tsx
interface Props{}
interface State{}
class Form extends Component<Props, State>{
protected submit(){
// contains a code when form submits
}
}
****************Login.tsx
class LoginForm extends Form{
render(){
return(
<View>
<Button onClick = {() => this.props.navigation.goBack()}
<Button onClick= {() => this.submit()} />
</View>
);
}
}
I wanna do this
<LoginForm navigation = {someObject} />
But I cannot do this because i cant seem to find a workaround. I just wanna know how to pass more props to LoginForm.