1
0
Fork 0
management/front/dkha-web-sz-main/node_modules/@babel/helper-get-function-arity
詹力 1a19ec897f 删除无关模块 2024-01-16 21:26:16 +08:00
..
lib 删除无关模块 2024-01-16 21:26:16 +08:00
README.md 删除无关模块 2024-01-16 21:26:16 +08:00
package.json 删除无关模块 2024-01-16 21:26:16 +08:00

README.md

@babel/helper-get-function-arity

Function that returns the number of arguments that a function takes.

  • Examples of what is considered an argument can be found at MDN Web Docs

Usage

import getFunctionArity from "@babel/helper-get-function-arity";

function wrap(state, method, id, scope) {
  // ...
  if (!t.isFunction(method)) {
    return false;
  }

  const argumentsLength = getFunctionArity(method);

  // ...
}