- Update .env.example to .env
- Update custom program ID in .env file
src/utils/idl
src/utils/Wallet.tsx
src/utils/Store.tsx
React Store uses useContext to allow all children components to access values in the Store.
signAndSendTransaction
function which takes a transaction, sets recentBlockhash and feePayers and then sends the transaction.
programClient
accessible with const { programClient } = useStoreContext();
In src/utils/pdaFetch.ts
, you will find 3 examples of fetching PDAs from your custom program.
getPdaAddressExample
returns the address of the PDAgetPdaDataExmaple
returns the single PDA datagetAllPdaByAuthority
returns an array of PDAs data that matches a filter