0.0.9 • Published 1 year ago

stateofnouns v0.0.9

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

README

Import into ES6 TypeScript project

import 'dotenv/config';

import * as nerman from "stateofnouns";

const Nouns = new nerman.Nouns(process.env.JSON_RPC_API_URL);

Nouns.on("VoteCast", (vote : EventData.VoteCast) => {

  Nouns.on("AuctionBid", (data) => {

    console.log("NounsAuctionHouse | AuctionBid " + data.id + " " + data.bidder.id + " " + data.amount + " " + data.extended);
    
  });

});

Import into CommonJS Project

require('dotenv').config();

const _nerman = import('stateofnouns');

async function runApp() {

const nerman = await _nerman; const Nouns = new nerman.Nouns(process.env.JSON_RPC_API_URL);

Nouns.on("AuctionBid", (data) => {

console.log("NounsAuctionHouse | AuctionBid " + data.id + " " + data.bidder.id + " " + data.amount + " " + data.extended);

});

}

runApp() .catch(err => { console.log(err); });

0.0.9

1 year ago

0.0.8

2 years ago

0.0.7

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago