MCPcopy Index your code
hub / github.com/CodebuffAI/codebuff / getOptionLabel

Function getOptionLabel

cli/src/components/ask-user/constants.ts:28–30  ·  view source on GitHub ↗
(option: AskUserOption)

Source from the content-addressed store, hash-verified

26
27/** Helper to extract label from an option (handles both string and object formats) */
28export const getOptionLabel = (option: AskUserOption): string => {
29 return typeof option === 'string' ? option : option?.label ?? ''
30}
31
32/** Constant for the "Custom" option index */
33export const CUSTOM_OPTION_INDEX: number = -1

Callers 4

MultipleChoiceFormFunction · 0.90
getAnswerDisplayFunction · 0.90
formatAnswerFunction · 0.90

Calls

no outgoing calls

Tested by 1

formatAnswerFunction · 0.72