Great article, I am a beginner in JavaScript and it was fun to learn this new syntax. I would like to add something. In the following topic: 饾棝饾棶饾椈饾棻饾椆饾棽 饾棻饾槅饾椈饾棶饾椇饾椂饾棸 饾椈饾棶饾椇饾棽 饾椊饾椏饾椉饾椊饾棽饾椏饾榿饾槅 饾槃饾椂饾榿饾椀 饾椉饾棷饾椃饾棽饾棸饾榿 饾棻饾棽饾榾饾榿饾椏饾槀饾棸饾榿饾槀饾椏饾椂饾椈饾棿 where you created a function to get the key value dynamically, I thought of also adding the object as a parameter, so that we can deal with multiple objects and not hard code one object inside the function. Here is the code for the same : function getPropertyValue(key,obj) { const {[key] : returnValue} = obj; return returnValue; } const student = { name : "Tony" } const nameFromEmp = getPropertyValue("name",employee); const nameFromStudent = getPropertyValue("name",student); console.log(NAME OF STUDENT IS : ${nameFromStudent}) console.log(NAME OF EMP IS : ${nameFromEmp})
