Eliminar del objeto JavaScript
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' }
Ofir Salem