Getting Started
Install the widget
To get started, install the latest version of OpenOcean Widget and required packages.
npm install @openocean.finance/widget wagmi @bigmi/react @solana/wallet-adapter-react @tanstack/react-query
Wagmi is type safe, extensible, and modular library for building Ethereum apps.
Bigmi is modular TypeScript library that provides reactive primitives for building Bitcoin applications.
@solana/wallet-adapter-react is modular TypeScript wallet adapters and components for Solana applications.
TanStack Query is an async state manager that handles requests, caching, and more. It is recommended to use version ^5.72.0 or above.
Basic example
Below is a basic example using OpenOcean Widget with container customization.
Example of loading the widget under a nested (second-level) route:
In the route configuration, change /trade
to /trade/*
:
<Route path="/trade/*" element={} />
Last updated