Appearance
数组的 Includes() : 用来检测数组中是否包含某个元素,返回true/false
Includes()
字符串也有includes方法
let a = [1, 2, 3, 4]; // 判断 console.log(a.includes(1)); // true let b = 'hello world'; console.log(b.includes('h')); // true