(React) ....map is not a function error

Hi every one am new here as well as react, i really need help with my code, i keep on getting this error
errooor.PNG

the link to the sandbox LINK

Comments (1)

Kleo Petrov's photo

You are changing the teachers array to a boolean in the handleView method.

Capture.PNG

I believe you wanted to update the value of showPersons instead of teachers.