New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 591188 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Sep 20
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Feature



Sign in to add a comment

Show parameters for native functions

Reported by eor...@gmail.com, Mar 1 2016

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.116 Safari/537.36

Steps to reproduce the problem:
1. Log a native function ex: console.log

What is the expected behavior?
Show the type of arguments the function can take

What went wrong?
Does not show parameters

Did this work before? No 

Chrome version: 48.0.2564.116  Channel: n/a
OS Version: 10.0
Flash Version: Shockwave Flash 20.0 r0

Look at the picture, it explains and shows examples
 
pic.png
57.0 KB View Download

Comment 1 by eor...@gmail.com, Mar 1 2016

One thing I have no idea how it would be done is **Optional** arguments
This would be really useful when learning new api's, just to see which arguments, optional and required and types a native implementation expects.

Comment 3 by alph@chromium.org, Mar 8 2016

Labels: -Type-Bug Type-Feature
Owner: lushnikov@chromium.org
Status: Assigned (was: Unconfirmed)

Comment 4 by eor...@gmail.com, Mar 8 2016

Just thought about it, a ? at the end could represent optional:

function someMethod(:String, :Array?) {}

Comment 5 by eor...@gmail.com, Apr 29 2016

Just thought about this, perhaps it would be easier to implement (not absolutely sure, because Idk how this works) if there was a method just for the console that would log basically "docs" for each native method just how we have `$` short for querySelector and `$$` for querySelectorAll but only works in the console

So:

console.docs(fetch); // would output a whole bunch of useful info about the method
Cc: lushnikov@chromium.org
Owner: kozyatinskiy@chromium.org
Alexey, any opportunity we can show function arguments for some of the native functions? (those which are implemented in js)

Comment 7 by caseq@chromium.org, Apr 19 2017

 Issue 713157  has been merged into this issue.
Owner: kozy@chromium.org
Owner: einbinder@chromium.org
Status: Fixed (was: Assigned)
I believe this one is fixed by Joel.

Sign in to add a comment