// 创建 symbolsconst mySymbol = Symbol('object name');const myObject = { firstName: 'raja', lastName: 'rao' };const keys = Object.keys(myObject);
const includes = Symbol('will store custom includes');Array.prototype[includes] = () => {console.log('inside includes func');};const arr = [1, 2, 3];
//测试:console.log(arr.includes(1));console.log(arr['includes'](1));arr[includes](1);