UNPKG

autotel

Version:
13 lines (12 loc) 616 B
//#region src/trace-factory-validation.ts /** * Validate the two stages of Autotel's public factory wrappers without * coupling helper modules to the large functional tracing implementation. */ function assertTraceFactory(helperName, value, stage = "factory") { if (typeof value === "function") return; throw new TypeError(stage === "factory" ? `${helperName}: expected a factory (ctx) => (...args) => result` : `${helperName}: factory must return a function; expected (ctx) => (...args) => result`); } //#endregion export { assertTraceFactory as t }; //# sourceMappingURL=trace-factory-validation-BjVAinz6.js.map