How to remove property from object in es6

const myObject = { "name": "my name", "city": "my city", "age": 18 };

we want to remove age property from above object


delete myObject.age;

delete myObject['age'];





Comments

Popular posts from this blog

world tourism guide Template

Es6 how to check if value is not null or undefined?