Skip to main content

Overview

The Bitcoin wallet provider supports Unisat, Leather, Xverse, and other Bitcoin wallets using the Bigmi library.

Installation

yarn add @layerswap/wallet-bitcoin @bigmi/client @bigmi/core @bigmi/react
Bigmi is modular TypeScript library that provides reactive primitives for building Bitcoin applications.

Basic Usage

The Bitcoin provider requires no configuration:
import { LayerswapProvider, Swap } from "@layerswap/widget"
import { createBitcoinProvider } from "@layerswap/wallet-bitcoin"
import "@layerswap/widget/index.css"

export const App = () => {
  const bitcoinProvider = createBitcoinProvider()

  return (
    <LayerswapProvider
      walletProviders={[bitcoinProvider]}
    >
      <Swap />
    </LayerswapProvider>
  )
}