web3/web/dist/hooks.js
2025-01-08 23:38:56 +07:00

14 lines
No EOL
413 B
JavaScript

import ZanoWallet from './zanoWallet';
import { useEffect, useState } from 'react';
function useZanoWallet(params) {
const [zanoWallet, setZanoWallet] = useState(null);
useEffect(() => {
if (typeof window === 'undefined') {
return;
}
setZanoWallet(new ZanoWallet(params));
}, []);
return zanoWallet;
}
export { useZanoWallet };
//# sourceMappingURL=hooks.js.map