DEV Community

Discussion on: find() vs filter()

Collapse
 
stegriff profile image
Ste Griffiths

Hi khush, welcome to Dev.to, and thanks for this post!

It's true, sometimes I use filter and then realise later that I'm only looking for one item and should use find instead!

Collapse
 
sudarshansb143 profile image
sudarshan

if you don't care about result then you can use .includes() also :)