MCPcopy Create free account
hub / github.com/effect-app/libs / getProgram

Function getProgram

repos/effect/packages/tools/jsdocs/src/Jsdocs.ts:1524–1538  ·  view source on GitHub ↗
(tsconfigPath: string)

Source from the content-addressed store, hash-verified

1522 }
1523 if (scope === "module" && since === null) {
1524 diagnostics.push(diagnostic("missing-tag", "Module JSDoc must include @since"))
1525 }
1526 if (since !== null && !stableSemverRegex.test(since)) {
1527 diagnostics.push(diagnostic("invalid-since", "@since must be a stable semver version like 1.2.3"))
1528 }
1529
1530 if (scope === "declaration") {
1531 const category = values.get("category")?.[0] ?? null
1532 if (category === null) diagnostics.push(diagnostic("missing-tag", "Public JSDoc must include @category"))
1533 if (category === "") diagnostics.push(diagnostic("empty-tag", "@category must include a value"))
1534 if (diagnostics.length > 0 || category === null || since === null) {
1535 return { _tag: "Failure", error: { diagnostics } }
1536 }
1537 return { _tag: "Success", value: { category, since, deprecated, see: see.map(parseSeeTag) } }
1538 }
1539
1540 if (scope === "member") {
1541 const defaultValue = values.get("default")?.[0] ?? null

Callers 1

extractJSDocsSyncFunction · 0.70

Calls 3

collectTsConfigFilesFunction · 0.85
getMethod · 0.65
setMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…