Skip to content

Commit 0c5209b

Browse files
authored
fix(hooks): add ERC20ABI, ERC721ABI exports (#217)
1 parent b66e93a commit 0c5209b

File tree

3 files changed

+13
-2
lines changed

3 files changed

+13
-2
lines changed

.changeset/moody-kangaroos-melt.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@web3-ui/hooks': minor
3+
'@web3-ui/core': patch
4+
---
5+
6+
Added `ERC20ABI` as an export of `@web3-ui/hooks` in order to resolve an incorrect import in the `@web3-ui/core` package.

packages/core/src/components/TokenGate/TokenGate.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React, { useCallback, useEffect, useState } from 'react';
22
import { TokenGate as PrivTokenGate } from '@web3-ui/components';
33
import { useReadOnlyContract, useWallet } from '@web3-ui/hooks';
4-
import { ERC20ABI, ERC721ABI } from '@web3-ui/hooks/src/constants';
4+
import { ERC20ABI, ERC721ABI } from '@web3-ui/hooks';
55
import { BigNumber, ethers } from 'ethers';
66

77
export interface TokenGateProps {

packages/hooks/src/index.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,9 @@ export {
88
usePoller
99
} from './hooks';
1010
export { Provider, Web3Context } from './Provider';
11-
export { NETWORKS, CHAIN_ID_TO_NETWORK, ERC721ABI } from './constants';
11+
export {
12+
NETWORKS,
13+
CHAIN_ID_TO_NETWORK,
14+
ERC20ABI,
15+
ERC721ABI,
16+
} from './constants';

0 commit comments

Comments
 (0)