score:0

Accepted answer

you can use some()

useeffect(() => {

 categoria && 
  setprodutosfiltrados(
    produtos.filter((item) => 
      object.entries(filtros).every(([key,value],i) =>{
        //here the value is an array 'variacoes' so to check colors use filter to get all the elements of 'variacoes' array;
        //also assuming that the color you are passing will be available here as item[key]
        var allcolors = item.map(i=>i.cor)
        return value.some((val)=>allcolors.includes(val.cor))
       }
      )
    )
  )

Related Query

More Query from same tag