Skip to content

Commit

Permalink
CR: Clean up imports & fix readme typos
Browse files Browse the repository at this point in the history
  • Loading branch information
mdbere committed Apr 8, 2024
1 parent b8e72af commit d84cf1b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 17 deletions.
6 changes: 3 additions & 3 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Noble <-> Ethereum (Typescript)
# Noble <-> Ethereum Bridging (Typescript)

## DepositForBurn instructions

1. Install require packages:
1. Install required packages:

```
npm install
Expand All @@ -27,7 +27,7 @@ The Noble testnet -> ETH Sepolia CCTP relayer should pick up these messages auto
## ReceiveMessage instructions
1. Install require packages:
1. Install required packages:
```
npm install
Expand Down
12 changes: 5 additions & 7 deletions examples/depositForBurn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,10 @@
* limitations under the License.
*/

import {GeneratedType, Registry} from "@cosmjs/proto-signing";

require("dotenv").config();
const { DirectSecp256k1HdWallet } = require("@cosmjs/proto-signing")
const { SigningStargateClient } = require("@cosmjs/stargate")
const { MsgDepositForBurn } = require("./generated/tx")
import "dotenv/config"
import { DirectSecp256k1HdWallet, Registry, GeneratedType } from "@cosmjs/proto-signing";
import { SigningStargateClient } from "@cosmjs/stargate";
import { MsgDepositForBurn } from "./generated/tx";

export const cctpTypes: ReadonlyArray<[string, GeneratedType]> = [
["/circle.cctp.v1.MsgDepositForBurn", MsgDepositForBurn],
Expand All @@ -33,7 +31,7 @@ function createDefaultRegistry(): Registry {

const main = async() => {

const mnemonic = process.env.MNEMONIC;
const mnemonic = process.env.MNEMONIC ? process.env.MNEMONIC : "";
const wallet = await DirectSecp256k1HdWallet.fromMnemonic(
mnemonic,
{
Expand Down
12 changes: 5 additions & 7 deletions examples/receiveMessage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,10 @@
* limitations under the License.
*/

import {GeneratedType, Registry} from "@cosmjs/proto-signing";

require("dotenv").config();
const { DirectSecp256k1HdWallet } = require("@cosmjs/proto-signing")
const { SigningStargateClient } = require("@cosmjs/stargate")
const { MsgReceiveMessage } = require("./generated/tx")
import "dotenv/config"
import { DirectSecp256k1HdWallet, Registry, GeneratedType } from "@cosmjs/proto-signing";
import { SigningStargateClient } from "@cosmjs/stargate";
import { MsgReceiveMessage } from "./generated/tx";

export const cctpTypes: ReadonlyArray<[string, GeneratedType]> = [
["/circle.cctp.v1.MsgReceiveMessage", MsgReceiveMessage],
Expand All @@ -33,7 +31,7 @@ function createDefaultRegistry(): Registry {

const main = async() => {

const mnemonic = process.env.MNEMONIC;
const mnemonic = process.env.MNEMONIC ? process.env.MNEMONIC : "";
const wallet = await DirectSecp256k1HdWallet.fromMnemonic(
mnemonic,
{
Expand Down

0 comments on commit d84cf1b

Please sign in to comment.