MCPcopy Create free account
hub / github.com/TanStack/cli / validate

Function validate

packages/cli/src/ui-prompts.ts:72–83  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

70 // Clack prints `undefined` on blank submit when placeholder is omitted.
71 placeholder: '',
72 validate(value) {
73 const projectName = value ?? ''
74
75 if (isCurrentDirectoryProjectNameInput(projectName)) {
76 return
77 }
78
79 const { valid, error } = validateProjectName(projectName)
80 if (!valid) {
81 return error
82 }
83 },
84 })
85
86 if (isCancel(value)) {

Callers

nothing calls this directly

Calls 2

validateProjectNameFunction · 0.85

Tested by

no test coverage detected