nexus-elements-swaps

Installation
SKILL.md

Nexus Elements - Swaps

Install

  • Install widget:
    • npx shadcn@latest add @nexus-elements/swaps
  • Ensure NexusProvider is installed and initialized before rendering.

Required setup before rendering

  • Ensure useNexus().nexusSDK is initialized.
  • Ensure swapBalance is fetched (fetchSwapBalance is called by hook if missing).

Initialize SDK (required once per app)

  • On wallet connect, resolve an EIP-1193 provider and call useNexus().handleInit(provider).
  • Wait for useNexus().nexusSDK before swap simulation starts.
  • Re-run init after reconnect if wallet session resets.

Render widget

"use client";
Related skills

More from availproject/nexus-elements

Installs
20
First Seen
Feb 4, 2026