The Method that I would recommend is using the metaplex JS SDK.
This example is ripped from Solana Cookbook.
import { Metaplex, keypairIdentity } from "@metaplex-foundation/js";
import { Connection, clusterApiUrl, Keypair, PublicKey } from "@solana/web3.js";
(async () => {
const connection = new Connection(clusterApiUrl("mainnet-beta"), "confirmed");
const keypair = Keypair.generate();
const metaplex = new Metaplex(connection);
metaplex.use(keypairIdentity(keypair));
const owner = new PublicKey("2R4bHmSBHkHAskerTHE6GE1Fxbn31kaD5gHqpsPySVd7");
const allNFTs = await metaplex.nfts().findAllByOwner(owner);
console.log(allNFTs);
})();
This example will only work locally, since it's using the keypair identity it will only work locally. Instead you can also use the connected wallets identity (e.g. like in this metaplex example). If you then want to find all NFTs of that wallet just call findAllByOwner(metaplex.identity().publicKey)