๐Ÿ“šย Reference


๐Ÿ“œย Chapter


includes()

includes()


arr.includes(valueToFind[, fromIndex])
let fruits = ["์‚ฌ๊ณผ", "๋ฐฐ", "ํ•œ๋ผ๋ด‰", "๋ฐ”๋‚˜๋‚˜"];

// true
console.log(fruits.includes("์‚ฌ๊ณผ"));

// false
console.log(fruits.includes("๋ณต์ˆญ์•„"));