MCPcopy Create free account
hub / github.com/tinyhttp/tinyhttp / setupPrettier

Function setupPrettier

packages/cli/src/index.ts:97–110  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

95 // CLI options
96
97 const setupPrettier = async () => {
98 msg(`Setting up Prettier`, 'green')
99 try {
100 await install(pkg, ['prettier'])
101 } catch {
102 throw new Error('Failed to install Prettier')
103 }
104
105 try {
106 await writeFile('.prettierrc', PRETTIER_CONFIG)
107 } catch {
108 throw new Error('Failed to create Prettier config')
109 }
110 }
111
112 if (options.full) {
113 setupPrettier()

Callers 1

index.tsFile · 0.85

Calls 2

msgFunction · 0.90
installFunction · 0.90

Tested by

no test coverage detected