How to use indexOf to find the Index of objects in JavaScript Array?

How to use indexOf to find the Index of objects in JavaScript Array?