title: How to check if key exists in the data from the server in javascript?
body: <p>I get some JSON values from the server but I don't know if there will be a particular field or not.</p>
  
  <p>Sometimes i get the response in this form</p>
  
  <pre><code>{
   "regatta_name":"ProbaRegatta",
    "country":"Congo",
    "status":"invited"
  }
  </code></pre>
  
  <p>Where as sometimes i get reponse in this form </p>
  
  <pre><code>{
   "regatta_name":"ProbaRegatta",
    "country":"Congo",
    "status":"invited",
     "vehicle": "yes"
  }
  </code></pre>
  
  <p>How to check if <strong>vehicle</strong> key exists in the javascript object.?</p>