Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@didux-io/web3-providers-http

ethereum6LGPL-3.01.0.0-beta.53

Module to handle web3 RPC connections over HTTP.

readme

web3-providers-http

This is a sub package of web3.js

This is a HTTP provider for web3.js.
Please read the documentation for more.

Installation

Node.js

npm install web3-providers-http

In the Browser

Build running the following in the web3.js repository:

npm run-script build-all

Then include dist/web3-providers-http.js in your html file. This will expose the Web3HttpProvider object on the window object.

Usage

// in node.js
var Web3HttpProvider = require('@didux-io/web3-providers-http');

var options = {
    timeout: 20000, // milliseconds,
    headers: [{name: 'Access-Control-Allow-Origin', value: '*'},{...}]
};
var http = new Web3HttpProvider('http://localhost:8545', options);

changelog

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

[4.0.1-alpha.2]

Changed

  • Updated Web3.js dependencies (#5664)

[4.0.1-alpha.3]

Changed

  • Updated dependencies (#5725)

[4.0.1-alpha.4]

Changed

  • main and files entries in package.json changed to lib/ directory from dist/ (#5739)

[4.0.1-alpha.5]

Changed

  • web3.js dependencies (#5757)

[4.0.1-rc.0]

Added

  • Added named export for HttpProvider (#5771)

[4.0.1-rc.1]

Added

  • Added source files (#5956)
  • Added hybrid build (ESM and CJS) of library (#5904)

[4.0.1-rc.2]

Changed

  • Dependencies updated

[4.0.1]

Release Notes:

Detailed List of change logs are mentioned under previous 4.x alpha and RC releases.

Documentation: Web3.js documentation Web3 API Migration Guide from 1.x

[4.0.2]

Changed

  • Dependencies updated

[4.0.3]

Changed

  • Dependencies updated

[4.0.4]

Changed

  • Dependencies updated

[4.0.5]

Changed

  • Dependencies updated

[4.0.6]

Changed

  • Dependencies updated

[4.1.0]

Changed

  • Bump cross-fetch to version 4 (#6463).

Fixed

  • Fix issue lquixada/cross-fetch#78, enabling to run web3.js in service worker (#6463)

[4.2.0]

Added

  • Added statusCode of response in ResponseError, statusCode is optional property in ResponseError.

[Unreleased]