@warpfi/vue shows the hosted Warp checkout on your page: inline, in a modal or in a popup. It needs Vue 3.3 or later and works with Nuxt 3. The checkout mounts in the browser only, so it is safe with server-side rendering.
npm · GitHub
Install
checkout_url. For a complete Nuxt walkthrough, see Set up with examples.
Inline checkout
checkout_url, pass :checkout-url instead. Changing it replaces the checkout with the new session.
Modal button
cancel if the payment has not completed), after the customer cancels, and after the customer returns from the success page. close is emitted last every time.
Use mode="popup" where your page cannot frame the checkout, or mode="redirect" to send the customer to the hosted page.
Composable
openModal and openPopup accept options that override those given to useWarpCheckout, and resolve to the checkout instance or null. Call openPopup directly from a click handler. The checkout closes when the component unmounts.
Global registration
plugins/warp.ts
Props and events
useWarpCheckout takes the same events as callbacks: onReady, onStatus, onComplete, onCancel, onReturn, onError and onClose.