Skip to content

KYRDTeam/web3-https-provider-liquid

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

web3-providers-http

This is a HTTP provider sub-package forked form https://github.com/web3/web3.js/tree/1.x/packages/web3-providers-http.

Installation

You can install the package either:

Using NPM

npm install https://github.com/KYRDTeam/web3-https-provider.git

Using Yarn

yarn add https://github.com/KYRDTeam/web3-https-provider.git

Usage

const http = require('http');
const Web3HttpProvider = require('web3-providers-http');

const options = {
    keepAlive: true,
    timeout: 20000, // milliseconds,
    headers: [{name: 'Access-Control-Allow-Origin', value: '*'},{...}],
    withCredentials: false,
    agent: {http: http.Agent(...), baseUrl: ''}
};

const provider = new Web3HttpProvider(['http://localhost:8545'], options);

Types

All the TypeScript typings are placed in the types folder.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published