0

This is a bit of a weird situation, but say I have the following function:

function myFunction(name, age, job){...}

Is there a way to get keys / loop through the required params for it (not the argument array passed to it), so it would be something like:

for(required_param_keys_by_myFunction){
 console.log(key) // --> name, age, job
}
Mankind1023
  • 7,198
  • 16
  • 56
  • 86

0 Answers0