MCPcopy
hub / github.com/baidu/amis / registerFormula

Function registerFormula

packages/amis-formula/src/function.ts:49–56  ·  view source on GitHub ↗
(
  name: string,
  fn: (this: Evaluator, ...args: Array<any>) => any,
  fnInfo?: FunctionDocItem
)

Source from the content-addressed store, hash-verified

47 * @param fnInfo
48 */
49export function registerFormula(
50 name: string,
51 fn: (this: Evaluator, ...args: Array<any>) => any,
52 fnInfo?: FunctionDocItem
53) {
54 registerFunction(name, fn);
55 fnInfo && registerFunctionDoc(fnInfo.namespace || 'Others', fnInfo);
56}

Callers

nothing calls this directly

Calls 2

registerFunctionFunction · 0.85
registerFunctionDocFunction · 0.85

Tested by

no test coverage detected