ts replace one property of object code example
Example: typescript obejct replace propertyies
const recievedKeys = Object.keys(receivedObject) as Array<keyof IEvent>
for (const key of recievedKeys) {
this.event = {
...this.event,
[key]: receivedObject[key]
}
}