@raidguild/use-chiev

    0.0.3 • Public • Published

    use-chiev

    use chiev nft info

    NPM JavaScript Style Guide

    Install

    yarn add @raidguild/use-chiev

    Usage

    import React, { Component } from 'react'
    import { useChievHook } from '@raidguild/use-chiev';
    
    const Example = () => {
      const { clones, getURI, numTokenOfGen0 } = useChievHook();
      useEffect(() => {
        const getOnChainData = async () => {
          const count = await numTokenOfGen0(
            "<eth address>",
            1
          );
          const uri = await getURI(1);
    
        };
        getOnChainData();
        // eslint-disable-next-line
      }, []);
    
      return (
          <div>
          <h1>Chiev Token Hook</h1>
          <p>clones.usersTokens has a lits of NFT owners and the tokens they own</p>
          <p>getURI will return the meta data uri from any token id</p>
          <p>numTokenOfGen0 will return the count of clones for a user for a gen0</p>
          </div>
      )
    }

    License

    MIT © dekanbro


    This hook is created using create-react-hook.

    Install

    npm i @raidguild/use-chiev

    DownloadsWeekly Downloads

    4

    Version

    0.0.3

    License

    MIT

    Unpacked Size

    778 kB

    Total Files

    26

    Last publish

    Collaborators

    • midgerate
    • bitbeckers
    • dekan