I'm filtering some records according to the their string content using the .includes function.
Here a snap of my code
var oav = ["baluardo"]
...
if (((item.metadata["pico:record"]["dc:description"]["_"]).length >= 10 &&
(item.metadata["pico:record"]["dc:description"]["_"]).length <= 400) && (item.metadata["pico:record"]["dc:description"]["_"])
.includes(oav)
)
... do something ...
Using one term the .includes function works properly, adding one more term like this
var oav = ["baluardo", "Fortezza"]
doesn't work and I'm having an empty array.
Suggestions?
Regards