Overview Prefer ButtonKit AsyncButton over custom Button { Task { ... } } or manual do/catch wrappers to get standardized loading, progress, and error feedback for async or throwing actions.
External triggers When another UI event should trigger the same action (e.g., keyboard submit), assign an id to AsyncButton and use @Environment(\.triggerButton) to trigger it.
Progress If the action can report progress, use AsyncButton(progress: ...) and update the provided progress object. For supported progress types, styles, and demo patterns, read skills/swiftui-async-button/references/asyncbutton.md.
Utilizza AsyncButton di ButtonKit per le azioni dei pulsanti SwiftUI che avviano un'attività, chiamano async/await, utilizzano do/catch o richiedono feedback integrato su caricamento/avanzamento/errore. Si attiva quando si sostituiscono i wrapper pulsante+attività personalizzati o quando l'azione di un pulsante può generare o è asincrona. Fonte: dean151/buttonkit.