(tagName: string, description: string | undefined, indent: string)
| 108 | } |
| 109 | |
| 110 | function xmlDocElement(tagName: string, description: string | undefined, indent: string): string[] { |
| 111 | if (!description) return []; |
| 112 | const escaped = ensureTrailingPunctuation(escapeXml(description.trim())); |
| 113 | const lines = escaped.split(/\r?\n/); |
| 114 | if (lines.length === 1) { |
| 115 | return [`${indent}/// <${tagName}>${lines[0]}</${tagName}>`]; |
| 116 | } |
| 117 | return [ |
| 118 | `${indent}/// <${tagName}>`, |
| 119 | ...lines.map((line) => `${indent}/// ${line}`), |
| 120 | `${indent}/// </${tagName}>`, |
| 121 | ]; |
| 122 | } |
| 123 | |
| 124 | function xmlDocNamedElement( |
| 125 | tagName: string, |
no test coverage detected
searching dependent graphs…