Javascript – check an element in object

/**
  * Code in javascript to check if an element exist in an object
  * @param obj: object
  * @param element : String
  * @return bool : TRUE(if exit)/FALSE(if not)
  */
obj.hasOwnProperty(element)
Advertisements