3f-web3-providers-http
TypeScript icon, indicating that this package has built-in type declarations

2.0.0 • Public • Published

3f-web3-providers-http

NPM Package Dependency Status Dev Dependency Status

This is a HTTP provider sub-package for web3.js.

Please read the documentation for more.

Installation

Node.js

npm install 3f-web3-providers-http

Usage

const http = require('http');
const Web3HttpProvider = require('3f-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.

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
2.0.00latest

Version History

VersionDownloads (Last 7 Days)Published
2.0.00
1.7.50

Package Sidebar

Install

npm i 3f-web3-providers-http

Weekly Downloads

0

Version

2.0.0

License

LGPL-3.0

Unpacked Size

17.7 kB

Total Files

9

Last publish

Collaborators

  • dnice