Skip to content

Commit

Permalink
fix package name
Browse files Browse the repository at this point in the history
  • Loading branch information
Zetazzz committed Aug 13, 2024
1 parent ce0a2bf commit 0702a2e
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 17 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,12 @@ We created a specific package to make it easy to migrate from `@cosmjs`.

- [interchainjs](/networks/cosmjs/README.md)

## Injective Network
## ethermint Network

### Transactions

- [@interchainjs/injective](/networks/injective/README.md)
- `@interchainjs/injective-msgs`(on progress)
- [@interchainjs/ethermint](/networks/ethermint/README.md)
- `@interchainjs/ethermint-msgs`(on progress)

## Ethereum Network

Expand Down
14 changes: 7 additions & 7 deletions networks/ethermint/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,28 +17,28 @@ Transaction codec and client to communicate with any injective blockchain.
## Usage

```sh
npm install @interchainjs/injective
npm install @interchainjs/ethermint
```

Taking `direct` signing mode as example.

```ts
// import * from "@interchainjs/injective"; // Error: use sub-imports, to ensure small app size
import { DirectSigner } from "@interchainjs/injective/direct";
// import * from "@interchainjs/ethermint"; // Error: use sub-imports, to ensure small app size
import { DirectSigner } from "@interchainjs/ethermint/direct";

const signer = new DirectSigner(<AUTH>, <ENCODER>[], <RPC_ENDPOINT>); // **ONLY** rpc endpoint is supported for now
const result = await signer.signAndBroadcast(<MESSAGE>[]);
console.log(result.hash); // the hash of TxRaw
```

- See [@interchainjs/auth](/packages/auth/README.md) to construct `<AUTH>`
- See `@interchainjs/injective-msgs`(on progress) to construct `<ENCODER>`s and `<CONVERTER>`s, and also different message types.
- See `@interchainjs/ethermint-msgs`(on progress) to construct `<ENCODER>`s and `<CONVERTER>`s, and also different message types.

## Implementations

- **direct signer** from `@interchainjs/injective/direct`
- **amino signer** from `@interchainjs/injective/amino`
- **eip712 signer** from `@interchainjs/injective/eip712`
- **direct signer** from `@interchainjs/ethermint/direct`
- **amino signer** from `@interchainjs/ethermint/amino`
- **eip712 signer** from `@interchainjs/ethermint/eip712`

## License

Expand Down
2 changes: 1 addition & 1 deletion networks/ethermint/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
throw new Error(
'@interchainjs/injective have no entry-point: consult README for usage'
'@interchainjs/ethermint have no entry-point: consult README for usage'
);
14 changes: 8 additions & 6 deletions packages/auth/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
<img src="https://user-images.githubusercontent.com/545047/188804067-28e67e5e-0214-4449-ab04-2e0c564a6885.svg" width="80">
</p>


<p align="center" width="100%">
<!-- <a href="https://github.com/cosmology-tech/interchainjs/actions/workflows/run-tests.yaml">
<img height="20" src="https://github.com/cosmology-tech/interchainjs/actions/workflows/run-tests.yaml/badge.svg" />
Expand Down Expand Up @@ -32,20 +31,23 @@ const signature = auth.sign(Uint8Array.from([1, 2, 3]));
console.log(signature.toHex());
```

It's easy to derive *cosmos/injective/ethereum* network HD path (taking `cosmos` as example)
It's easy to derive _cosmos/injective/ethereum_ network HD path (taking `cosmos` as example)

```ts
// derive with Cosmos default HD path "m/44'/118'/0'/0/0"
const auth = Secp256k1Auth.fromMnemonic("<MNEMONIC_WORDS>", "cosmos");
// is identical to
const auth = Secp256k1Auth.fromMnemonic("<MNEMONIC_WORDS>", "m/44'/118'/0'/0/0");
// is identical to
const auth = Secp256k1Auth.fromMnemonic(
"<MNEMONIC_WORDS>",
"m/44'/118'/0'/0/0"
);
```

`Auth` objected can be utilized by different signers. See

- [@interchainjs/cosmos](/networks/cosmos/README.md)
- [@interchainjs/ethereum](/networks/ethereum/README.md)
- [@interchainjs/injective](/networks/injective/README.md)
- [@interchainjs/ethermint](/networks/injective/README.md)

## Implementations

Expand All @@ -56,4 +58,4 @@ const auth = Secp256k1Auth.fromMnemonic("<MNEMONIC_WORDS>", "m/44'/118'/0'/0/0")

MIT License (MIT) & Apache License

Copyright (c) 2024 Cosmology (https://cosmology.zone/)
Copyright (c) 2024 Cosmology (https://cosmology.zone/)

0 comments on commit 0702a2e

Please sign in to comment.