Nodes/ComfyUI CoolB Nodes/CB String List Match Index ⚡️
ComfyUI Node

CB String List Match Index ⚡️

Compares an input string against a list using custom matching rules. Returns a 1-based index if matched, or 0 if not found.

By CoolBreeze164·Created 9 days ago·Updated about 16 hours ago· 0
CB String List Match Index ⚡️
    • index
    • matched
    ◄input_string►
    ◄string_listapple banana cherry►
    ◄delimiternewline►
    ◄match_modeEqual►
    ◄case_sensitivetrue►
    CategoryCoolB Nodes ⚡️

    Inputs (5)

    NameTypeDefaultDescription
    input_stringSTRINGThe target text you want to search for in the list.
    string_listSTRINGapple banana cherryThe list of existing strings to look through. Format based on your chosen delimiter.
    delimiterCOMBOnewlineHow the string list is split. Choose 'newline' if each item is on its own line.
    match_modeCOMBOEqualHow the input string should match items in the list. 'Equal' requires an exact match.
    case_sensitiveBOOLEANtrueIf True, 'Apple' and 'apple' will be treated as different strings.

    Outputs (2)

    NameTypeDescription
    indexINT—
    matchedBOOLEAN—