MCPcopy
hub / github.com/donmccurdy/glTF-Transform / formatParagraph

Function formatParagraph

packages/cli/src/utils/format.ts:22–27  ·  view source on GitHub ↗
(str: string)

Source from the content-addressed store, hash-verified

20}
21
22export function formatParagraph(str: string): string {
23 return str
24 .match(/.{1,80}(\s|$)/g)!
25 .map((line) => line.trim())
26 .join('\n');
27}
28
29export function formatHeader(title: string): string {
30 return '' + '\n ' + title.toUpperCase() + '\n ────────────────────────────────────────────';

Callers 2

util.test.tsFile · 0.90
reportSectionFunction · 0.85

Calls 1

matchMethod · 0.65

Tested by

no test coverage detected