Posted By

michaJlS on 04/22/11


Tagged


Versions (?)

How to list the properties of a javascript object


 / Published in: JavaScript
 

URL: http://stackoverflow.com/questions/208016/how-to-list-the-properties-of-a-javascript-object

  1. var getKeys = function(obj){
  2. var keys = [];
  3. for(var key in obj){
  4. keys.push(key);
  5. }
  6. return keys;
  7. }

Report this snippet  

You need to login to post a comment.