MCPcopy Create free account
hub / github.com/microsoft/SandDance / optional

Function optional

docs/app/js/sanddance-app.js:138053–138055  ·  view source on GitHub ↗
(f)

Source from the content-addressed store, hash-verified

138051parcelHelpers.export(exports, "optional", ()=>optional);
138052parcelHelpers.export(exports, "required", ()=>required);
138053function optional(f) {
138054 return f == null ? null : required(f);
138055}
138056function required(f) {
138057 if (typeof f !== "function") throw new Error;
138058 return f;

Callers

nothing calls this directly

Calls 1

requiredFunction · 0.70

Tested by

no test coverage detected