useConfirm

Opens a confirmation dialog and resolves the answer as a promise. The dialog renders with the caller's app context, so the router, plugins and app-level provides reach it. Only one is open at a time: a second confirm() answers the first with false.

Install: pnpm add-composable useConfirm

Await the answer

Call useConfirm() in setup, then await confirm(). Enter on the focused Cancel button cancels: only Enter elsewhere in the dialog confirms.

API