I am working on project in ReactJS, I am fetching data from server through API. I did some search filtration, I want to display message if there is no records available? I a
You can add your message as another conditional wherever you'd like:
{this.state.filtered.length === 0 && ( Your Message )}
Or if you're trying to add a message for getting no results at all, then:
{this.state.allData.length === 0 && ( Your Message )}