Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/sigmagmbh/swisstronik-ethersjs-example-usage

Example of using Swisstronik Ethers.js fork to interact with the chain
https://github.com/sigmagmbh/swisstronik-ethersjs-example-usage

blockchain defi deoxys encryption ethers ethersjs evm evm-blockchain swisstronik web3

Last synced: 18 days ago
JSON representation

Example of using Swisstronik Ethers.js fork to interact with the chain

Awesome Lists containing this project

README

        

# Swisstronik Ethers.js Example Usage

This repo is created to showcase the usage of [Swisstronik's Ethers.js fork](https://github.com/SigmaGmbH/ethers.js) to interact with the network.

The library itself is created for the most popular Ethers.js version, v5.7.2.

It is entirely drop-in replacement, preserving all regular Ethers functionality and adds special encryption / decryption code only for Swisstronik network.
That means you can use it directly with your existing applications.

In order to start using Swisstronik Ethers.js:

1. Replace dependency in your `package.json`:

`"ethers": "^5.7.0"` // or other version before ethers v6

to

`"@swisstronik/ethers": "^572.0.2"`

2. Replace imports in your code:

`import { ethers, providers, Wallet } from "ethers";`

to

`import { ethers, providers, Wallet } from "@swisstronik/ethers";`

After that you should be ready to use your code as normal with Swisstronik network.