I would like to check if a String exists in my array.
My Javascript Code :
if(Ressource.includes("Gold") === true )
{
alert('Gold is in my arrray');
}
So Ressource is my array and this array contains :
Ressource ["Gold 780","Platin 500"] // I printed it to check if it was true
I don't understand why my test if(Ressource.includes("Gold") === true don't work.
Best regards, I hope someone knows what is wrong with this.