Catalog npm
PACKAGE EXPLORERView in registry

@0xsequence/deployer

npm

deployer sub-package for Sequence

Versions collected570
Direct dependencies4From release 2.3.47
Last observed21 Oct, 10:14 UTC

README

Current package documentation

@0xsequence/deployer

Deploy contracts using a universal deployer via CREATE2, allowing contracts to have the same address on any EVM chain.

UniversalDeployer works in both Web Browsers and Nodejs.

For more info, see 0xsequence project page.

How to use

  1. yarn add @0xsequence/deployer
  2. Import UniversalDeployer into script
  3. Create UniversalDeployer instance
  4. Deploy contracts

An instance number can be passed if multiple instance of the same contract need to be deployed on the same chain. The default instance number is 0, if none is passed.

...
import { UniversalDeployer } from '@0xsequence/deployer'

const provider = new Web3Provider(web3.currentProvider)
const universalDeployer = new UniversalDeployer(network.name, provider)

const main = async () => {
  await universalDeployer.deploy('Factory', FactoryFactory)
  await universalDeployer.deploy('MainModuleUpgradable', MainModuleUpgradableFactory)
  await universalDeployer.deploy('GuestModule', GuestModuleFactory)

  prompt.start(`writing deployment information to ${network.name}.json`)
  await universalDeployer.registerDeployment()

  // or, await universalDeployer.getDeployment()

  prompt.succeed()
}

main()

You can also pass transaction parameters explicitly :

...

const main = async () => {
  await universalDeployer.deploy('WalletFactory', FactoryFactory, { gasLimit: 1000000 })
  await universalDeployer.deploy('MainModuleUpgradable', MainModuleUpgradableFactory, { gasPrice: 10n ** 9n })
}


License

License: MIT

Copyright (c) 2018-present Horizon Blockchain Games Inc.

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Versions 570

Collected releases
VersionPublishedDirect dependenciesOpen version
1.9.027 Feb 20249
1.8.823 Feb 20249
0.0.0-2024021519122515 Feb 20249
0.0.0-2024021517202315 Feb 20249
0.0.0-2024021517035015 Feb 20249
1.8.713 Feb 20249
1.8.69 Feb 20249
1.8.59 Feb 20249
1.8.41 Feb 20249
1.8.331 Jan 20249
0.0.0-2024013118003031 Jan 20249
1.8.229 Jan 20249
1.8.124 Jan 20249
0.0.0-2024012315341023 Jan 20249
0.0.0-2024012314591923 Jan 20249
0.0.0-2024012314560723 Jan 20249
1.8.023 Jan 20249
1.7.222 Jan 20249
0.0.0-2024011911372619 Jan 20249
1.7.118 Jan 20249

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Repository

PENDING
0xsequence/sequence.js

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 10:09 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:63f01385b295e06c411f2a07ae575bdb2079cf7c2d44ea979a2e399a143f940a