Getting Started

Overview

fether provides a system for continuous frictionless connection between front end and back end developers work on decentralized applications.

fether is in its infancy and currently very opinionated. Namely, fether works exclusively with repositories using Foundry as their smart contract development framework.

fether Typescript Module provides a persistent updated ABI and contract address to use with your Ethereum interaction library of choice.

Installation

npm i fetherkit

Quickstart

1. Follow steps on fether.xyz to get API key and install Github app

Fether currently requires an alpha access key to use. DM @0xFloop on twitter to get one :)

2. Setup your fether instance

import Fether from "fetherkit";
const fether = new Fether(YOUR_API_KEY);

3. Initialize your fether instance

This can most easily be done within the useEffect hook, this loads your fether instance with all the data connected to your api key

  useEffect(() => {
    fether.init();
    setWindowEthereum(window.ethereum as Ethereum);

    return () => {};
  }, []);

4. Use fether!

Now you can swap any instance of contract address or contract abi with your data from fether!


  let publicClient = createPublicClient({
    chain: fether.chain,
    transport: http(),
  });

  const number = await publicClient.readContract({
      address: fether.address,
      abi: fether.abi,
      functionName: "getLeNumber",
    });

Last updated