MCPcopy Create free account
hub / github.com/AlmostEfficient/full-stack-solana-dev / App

Function App

front-end/src/App.tsx:22–46  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

20import '@solana/wallet-adapter-react-ui/styles.css';
21
22function App() {
23 // The network can be set to 'devnet', 'testnet', or 'mainnet-beta'.
24 const network = WalletAdapterNetwork.Devnet;
25 // You can also provide a custom RPC endpoint.
26 const endpoint = useMemo(() => clusterApiUrl(network), [network]);
27
28 const wallets = useMemo(
29 () => [new PhantomWalletAdapter()],
30 // eslint-disable-next-line react-hooks/exhaustive-deps
31 [network]
32 );
33
34 return (
35 <ConnectionProvider endpoint={endpoint}>
36 <WalletProvider wallets={wallets} autoConnect>
37 <WalletModalProvider>
38 <WalletMultiButton />
39 <h1>Hello Solana</h1>
40 <CounterState />
41 <IncrementButton />
42 </WalletModalProvider>
43 </WalletProvider>
44 </ConnectionProvider>
45 );
46}
47
48export default App;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected