Would some like Object.inspect(myObj) be useful?
Hemanth H.M
hemanth.hm at gmail.com
Thu Jun 14 10:17:52 PDT 2012
var info = { name: "Hemanth", url: "http://h3manth.com/", location :
"Earth", get : function() {} };
Object.keys(info)
["name", "url", "location", "get"]
Now, it's not clear about the 'type' of the keys; name is a String, where
as get is a function.
Compared to something like inspect module in python that give o/p like :
('__delslice__', <method-wrapper '__delslice__' of list object at
0x1005252d8>)
On Thu, Jun 14, 2012 at 10:41 PM, Allen Wirfs-Brock
<allen at wirfs-brock.com>wrote:
>
> On Jun 14, 2012, at 9:49 AM, Hemanth H.M wrote:
>
> The inspect module provides functions for introspecting on live objects
> and their source code.
>
>
> As do many of the ES5 methods in Object.*. It's not clear what you mean
> by source code in this context.
>
> If you want to have discussion about an idea like this you have to provide
> a much more complete description of what you have in mind.
>
> Allen
>
>
>
>
--
*'I am what I am because of who we all are'*
h3manth.com <http://www.h3manth.com>
*-- Hemanth HM *
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20120614/5557211c/attachment.html>
More information about the es-discuss
mailing list