JSPM

get-params

0.1.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 174402
  • Score
    100M100P100Q155323F
  • License MIT

Get a list of function's argument variable names

Package Exports

  • get-params

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (get-params) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

get-params

Build Status

Get a list of function's argument variable names (parameters).

Install

$ npm install --save get-params

Usage

var getParams = require('get-params');

var myFunction = function (one, two, three) {
    return 'blah';
};

var params = getParams(myFunction);
console.log(params); // ['one', 'two', 'three']

Browser

You can also run it in the browser. Install it with bower:

$ bower install --save get-params

Include the script in your HTML:

<script src="./bower_components/get-params/index.js"></script>

The library will be available in window.GetParams:

var params = GetParams(myFunction);

License

MIT © Fahad Ibnay Heylaal