title: google drive javascript api gapi.client.drive.files undefined
body: <p>The JavaScript example to list files of Google Drive uses <code>gapi.client.drive.files.list()</code>.
  When trying to use this method I get the error "Cannot read property 'files' of undefined".</p>
  
  <p>The issue and a workaround are already described under <a href="https://stackoverflow.com/questions/11315962">Google Drive API javascript</a></p>
  
  <p>Is the documentation under <a href="https://developers.google.com/drive/v2/reference/files/list#try-it" rel="nofollow noreferrer">https://developers.google.com/drive/v2/reference/files/list#try-it</a> incorrect? Or is there a way to use the API as described.</p>