MCPcopy
hub / github.com/prettier/prettier / createOptionUsageRow

Function createOptionUsageRow

src/cli/usage.js:46–55  ·  view source on GitHub ↗
(header, content, threshold)

Source from the content-addressed store, hash-verified

44}
45
46function createOptionUsageRow(header, content, threshold) {
47 const separator =
48 header.length >= threshold
49 ? `\n${" ".repeat(threshold)}`
50 : " ".repeat(threshold - header.length);
51
52 const description = content.replaceAll("\n", `\n${" ".repeat(threshold)}`);
53
54 return `${header}${separator}${description}`;
55}
56
57function createOptionUsageType(option) {
58 switch (option.type) {

Callers 2

createChoiceUsagesFunction · 0.85
createOptionUsageFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…