Integrate Abstraxn Smart Wallets into your Next.js application
Now that you’ve set up your provider configuration, it’s time to integrate Abstraxn Smart Wallets into your Next.js application.

Using the Connect Button

The ConnectButton component is a ready-to-use button that triggers the onboarding modal:

Using Hooks

You can use the provided hooks to access wallet state and functionality:

Sending Transactions

For embedded-wallet EVM transactions, use: usePrepareRawTxn -> useSignAndSendTxn -> useWaitForTxnReceipt

Alternative: Using Hook to Trigger Onboarding

You can also trigger the onboarding modal programmatically using the showOnboarding method:

Complete Example

Here’s a complete example combining all the pieces:

Next Steps