MCPcopy Index your code
hub / github.com/alibaba/lowcode-engine / newFunction

Function newFunction

packages/utils/src/script.ts:54–62  ·  view source on GitHub ↗
(args: string, code: string)

Source from the content-addressed store, hash-verified

52}
53
54export function newFunction(args: string, code: string) {
55 try {
56 // eslint-disable-next-line no-new-func
57 return new Function(args, code);
58 } catch (e) {
59 logger.warn('Caught error, Cant init func');
60 return null;
61 }
62}

Callers 1

script.test.tsFile · 0.90

Calls 1

warnMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…