useChain

This hook provides data regarding the current user network and all the supported chains the user has passed to the KitProvider wrapper.

Usage

import { useChain } from '@nazeeh2000/comp-kit'

const Comp = () => {
   const { currentChain } = useChain();
  
  return (
  // Your component
  )
}

Return values

const {
    currentChain,
    supportedChains // returns an array of Chains of type Chain[]
} = useChain()

Last updated