Function classNames

  • Example

        const cls = classNames( 'class1 class2', {
    'class3': false,
    'class4': true,
    });

    // even shorter
    const class1 = true, class2 = false;
    const cls = classNames( { class1, class2 } ); // cls = "class1"

    Parameters

    • Rest ...args: any[]

    Returns string

Generated using TypeDoc