import { useEffect, useState } from "react";
import { useBundler } from "./useBundler";
export const useUserSCWallet = () => {
const { walletAPI } = useBundler();
const [userSCWalletAddress, setUserSCWalletAddress] = useState<any>("");
useEffect(() => {
(async () => {
if (walletAPI) {
setUserSCWalletAddress(await walletAPI.getAccountAddress());
}
})();
}, [walletAPI]);
return userSCWalletAddress;
};