Skip to content

Commit

Permalink
Add groupOfAddress method
Browse files Browse the repository at this point in the history
  • Loading branch information
Prakash-Shelar committed Oct 25, 2024
1 parent b634f38 commit bd1d381
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/sdk/web3-react.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ will connect to address from any group.
Note: When interacting with a deployed smart contract, use the same `addressGroup` that was specified during deployment. To identify the `addressGroup` of a deployed contract, use the following code:

```typescript
const nftCollection = NFTCollection.at(contractAddress);
const index = await nftCollection.groupIndex;
import { groupOfAddress } from '@alephium/web3';
const index = groupOfAddress(contractAddress);
```

This code retrieves the group index associated with the contract, confirming the correct `addressGroup`.
Expand Down

0 comments on commit bd1d381

Please sign in to comment.