def format_event_handler(handler: EventHandler) -> str:
    """Format an event handler.

    Args:
        handler: The event handler to format.

    Returns:
        The formatted function.
    """
    state, name = get_event_handler_parts(handler)
    if state == "":
        return name
    return f"{state}.{name}"
Format an event handler.

    Args:
        handler: The event handler to format.

    Returns:
        The formatted function.
    
reflex/utils/format.py