Open josephakayesi opened 6 years ago
Insert this on your constructor
constructor(props) { super(props); this.modalRef = null }
Update your ref attribute on your modal Component to ` <Modal ref={element => this.modalRef = element}
`
and use this.modalRef
to access Modal's function
Source: React Documenation
How do I fix this issue when using the modal box please ?