@openzeppelin/upgrades

JavaScript library for the OpenZeppelin smart contract platform

The OpenZeppelin SDK is no longer being developed. For smart contract upgrades check out the OpenZeppelin Upgrades Plugins. https://zpl.in/upgrades-plugins
Last updated 10 months ago by frangio .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @openzeppelin/upgrades 
SYNC missed versions from official npm registry.

OpenZeppelin SDK JavaScript Library (@openzeppelin/upgrades)

standard-readme compliant NPM Package CircleCI

JavaScript library for the OpenZeppelin smart contract platform.

OpenZeppelin SDK is a platform to develop, deploy and operate smart contract projects on Ethereum and every other EVM and eWASM-powered blockchain.

This is the repository for the OpenZeppelin SDK JavaScript library. It is mainly used by the openzeppelin-sdk command-line interface, which is the recommended way to use the OpenZeppelin SDK; but this library can also be used directly to operate projects when a programmatic interface is preferred or more flexibility and lower-level access is required.

Install

First, install Node.js and npm. Then, install the OpenZeppelin SDK JavaScript Library running:

npm install @openzeppelin/upgrades

Usage

Suppose there is a contract called MyContract in the file contracts/MyContract.sol, already compiled to build/contracts/MyContract.json, and that there is a development blockchain network running locally in port 9545.

Open a Node.js console:

node
> const { ZWeb3, Contracts, SimpleProject } = require('@openzeppelin/upgrades')
> // Initialize a web3 provider.
> ZWeb3.initialize("http://localhost:9545")
> // Load the contract.
> const MyContract = Contracts.getFromLocal('MyContract')
> // Instantiate a project.
> myProject = new SimpleProject('MyProject', { from: await ZWeb3.defaultAccount() })
> // Create a proxy for the contract.
> myProject.createProxy(MyContract).then(proxy => myProxy = proxy)
> // Make a change on the contract, and compile it.
> const MyContractUpgraded = Contracts.getFromLocal('MyContract')
> myProject.upgradeProxy(proxy, MyContractUpgraded)

Security

If you find a security issue, please contact us at security@openzeppelin.com. We give rewards for reported issues, according to impact and severity.

API

TODO.

Maintainers

Contribute

To contribute, join our community channel on Telegram where you can talk to all the OpenZeppelin developers, contributors, partners and users.

You can also follow the recent developments of the project in our blog and Twitter account.

License

MIT © OpenZeppelin

Current Tags

  • 2.6.0-byzantium.0                                ...           byzantium (a year ago)
  • 2.8.0                                ...           latest (10 months ago)

23 Versions

  • 2.8.0 [deprecated]           ...           10 months ago
  • 2.8.0-rc.4                                ...           10 months ago
  • 2.8.0-rc.3                                ...           10 months ago
  • 2.7.2 [deprecated]           ...           10 months ago
  • 2.8.0-rc.2                                ...           a year ago
  • 2.8.0-rc.1                                ...           a year ago
  • 2.8.0-rc.0                                ...           a year ago
  • 2.7.1 [deprecated]           ...           a year ago
  • 2.7.0 [deprecated]           ...           a year ago
  • 2.7.0-rc.4                                ...           a year ago
  • 2.7.0-rc.2                                ...           a year ago
  • 2.7.0-rc.1                                ...           a year ago
  • 2.7.0-rc.0                                ...           a year ago
  • 2.6.0-byzantium.0                                ...           a year ago
  • 2.6.0 [deprecated]           ...           a year ago
  • 2.6.0-rc.1                                ...           a year ago
  • 2.6.0-rc.0                                ...           a year ago
  • 2.5.3 [deprecated]           ...           a year ago
  • 2.5.2 [deprecated]           ...           a year ago
  • 2.5.1 [deprecated]           ...           a year ago
  • 2.5.0 [deprecated]           ...           2 years ago
  • 2.5.0-rc.1                                ...           2 years ago
  • 2.5.0-rc.0                                ...           2 years ago
Downloads
Today 0
This Week 8
This Month 71
Last Day 2
Last Week 37
Last Month 97
Dependencies (15)
Dev Dependencies (26)

Copyright 2014 - 2016 © taobao.org |