Interactive Javascript Help info.

Hi

I've been using python for a couple of years now, and there's one thing I
really love about it. It's the way you can interactively get documentation
for modules, classes and functions. You can do this simply by calling

help(something)

I'm often playing around with javascript in the browser console, which
works very much like Python's REPL (the interactive mode), and I thought
it'd be awesome to be able to do that.

For example, this morning, I was trying to figure out which arguments
navigator.registerProtocolHandler takes, and I had to open a new tab,
google it, and come back to the tab where I had the dev tools open. It
would be so much quicker if I could have just typed
help(navigator.registerProtocolHandler), and gotten a string back
documenting its signature, and maybe a couple of words about what it does,
nothing extensive.

I'm not sure whether this is the right place to discuss this idea. Maybe I
should post this on some ecmascript mailing list, but it seems like this
would be quite easy to implement if the web platform had some kind of API
we could call, with CORS enabled. This way, the help info could be updated
without a browser update.


I'm new to this mailing list, so I'm sorry if this message is completely in
the wrong place.


best regards
Frederik

Received on Thursday, 1 May 2014 15:44:00 UTC