const employee = {
id:1,
name: 'ofir',
salary: 1000
};
const {salary, ...newEmployee } = employee;
console.log( newEmployee );
// { id: 1, name: 'ofir' }
/***** OR ******/
delete employee.salary;
console.log( employee );
// { id: 1, name: 'ofir' }
delete object.element
delete object.element;
delete object in javascript
remove element from an object