const obj = { id: 1, name: 'John', age: 30, gender: 'male' }; const { gender, ...newObj } = obj; console.log(newObj); // {id: 1, name: "John", age: 30}