0.0.9 • Published 3 years ago

stateofnouns v0.0.9

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years 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

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago