MCPcopy Create free account
hub / github.com/Effect-TS/effect / extractInlineLinkTarget

Function extractInlineLinkTarget

packages/tools/jsdocs/src/Jsdocs.ts:1687–1692  ·  view source on GitHub ↗
(linkText: string)

Source from the content-addressed store, hash-verified

1685}
1686
1687function extractInlineLinkTarget(linkText: string): string {
1688 const content = linkText.slice("{@link".length, linkText.endsWith("}") ? -1 : undefined).trim()
1689 const pipeIndex = content.indexOf("|")
1690 const beforeLabel = pipeIndex === -1 ? content : content.slice(0, pipeIndex).trim()
1691 return beforeLabel.split(/\s+/)[0] ?? ""
1692}
1693
1694function malformedInlineLinks(block: JSDocBlock): Array<string> {
1695 const source = block.lines.join("\n")

Callers 3

malformedInlineLinksFunction · 0.85
addJSDocLinkDiagnosticsFunction · 0.85

Calls 3

trimMethod · 0.80
sliceMethod · 0.80
splitMethod · 0.45

Tested by

no test coverage detected