@ada-anvil/sdk-enhancer-react
TypeScript icon, indicating that this package has built-in type declarations

0.4.0 • Public • Published


Anvil SDK React Enhancer

Website

This enhancer adds React hooks that can be used to make some Anvil Client SDK data reactive.

Installation

npm install @ada-anvil/sdk-core @ada-anvil/sdk-enhancer-react

Usage

import { reactEnhancer } from "@ada-anvil/sdk-enhancer-react";

const enhancedSdk = anvil.enhance(reactEnhancer);

function ReactComp() {
  const wallet = enhancedSdk.enhancers.react.wallet.useName();

  return <div>Connected wallet: {wallet}</div>;
}

Readme

Keywords

none

Package Sidebar

Install

npm i @ada-anvil/sdk-enhancer-react

Weekly Downloads

35

Version

0.4.0

License

none

Unpacked Size

7.95 kB

Total Files

6

Last publish

Collaborators

  • dodilanne
  • tqueri
  • pabz-anvil
  • mrabdibdi-anvil