Skip to content

Instantly share code, notes, and snippets.

@ydm
Last active July 18, 2023 11:52
Show Gist options
  • Select an option

  • Save ydm/3a389d8537e3e0749799ddb0f1aec125 to your computer and use it in GitHub Desktop.

Select an option

Save ydm/3a389d8537e3e0749799ddb0f1aec125 to your computer and use it in GitHub Desktop.
import React, { useEffect, useState } from 'react';
interface Wallet {
accounts: Array<string>;
}
function App(): React.JSX.Element {
// Provider
const [
hasProvider,
setHasProvider,
]: [
boolean,
React.Dispatch<React.SetStateAction<boolean>>,
] = useState<boolean>(false);
const [
wallet,
setWallet,
]: [
Wallet,
React.Dispatch<React.SetStateAction<Wallet>>,
] = useState({ accounts: Array<string>() });
return <></>;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment