Conditionally Add Properties to Object in JavaScript | If Condition Inside Object JavascriptHow to use if condition inside