From 2fa7d0948bdabd8f2261cc4c14d116f83dfc29f5 Mon Sep 17 00:00:00 2001 From: nickfrosty <75431177+nickfrosty@users.noreply.github.com> Date: Mon, 25 Nov 2024 20:16:01 -0500 Subject: [PATCH] fix: broken link and typos --- content/cookbook/tokens/approve-token-delegate.md | 4 ++-- content/cookbook/tokens/burn-tokens.md | 4 ++-- content/cookbook/tokens/create-mint-account.md | 2 +- content/cookbook/tokens/set-update-token-authority.md | 2 +- content/cookbook/tokens/transfer-tokens.md | 4 ++-- content/cookbook/transactions/offline-transactions.md | 8 ++++---- content/courses/connecting-to-offchain-data/oracles.md | 4 ++-- .../verifiable-randomness-functions.md | 2 +- content/guides/getstarted/scaffold-nextjs-anchor.md | 2 +- 9 files changed, 16 insertions(+), 16 deletions(-) diff --git a/content/cookbook/tokens/approve-token-delegate.md b/content/cookbook/tokens/approve-token-delegate.md index f2697b028..b64d457b1 100644 --- a/content/cookbook/tokens/approve-token-delegate.md +++ b/content/cookbook/tokens/approve-token-delegate.md @@ -62,7 +62,7 @@ import bs58 from "bs58"; tokenAccountPubkey, // token account randomGuy.publicKey, // delegate alice, // owner of token account - 1e8, // amount, if your deciamls is 8, 10^8 for 1 token + 1e8, // amount, if your decimals is 8, 10^8 for 1 token 8, // decimals ); console.log(`txhash: ${txhash}`); @@ -77,7 +77,7 @@ import bs58 from "bs58"; mintPubkey, // mint randomGuy.publicKey, // delegate alice.publicKey, // owner of token account - 1e8, // amount, if your deciamls is 8, 10^8 for 1 token + 1e8, // amount, if your decimals is 8, 10^8 for 1 token 8, // decimals ), ); diff --git a/content/cookbook/tokens/burn-tokens.md b/content/cookbook/tokens/burn-tokens.md index e5e997939..486b297af 100644 --- a/content/cookbook/tokens/burn-tokens.md +++ b/content/cookbook/tokens/burn-tokens.md @@ -52,7 +52,7 @@ import bs58 from "bs58"; tokenAccountPubkey, // token account mintPubkey, // mint alice, // owner - 1e8, // amount, if your deciamls is 8, 10^8 for 1 token + 1e8, // amount, if your decimals is 8, 10^8 for 1 token 8, ); console.log(`txhash: ${txhash}`); @@ -67,7 +67,7 @@ import bs58 from "bs58"; tokenAccountPubkey, // token account mintPubkey, // mint alice.publicKey, // owner of token account - 1e8, // amount, if your deciamls is 8, 10^8 for 1 token + 1e8, // amount, if your decimals is 8, 10^8 for 1 token 8, // decimals ), ); diff --git a/content/cookbook/tokens/create-mint-account.md b/content/cookbook/tokens/create-mint-account.md index bf12c0ce1..a65119321 100644 --- a/content/cookbook/tokens/create-mint-account.md +++ b/content/cookbook/tokens/create-mint-account.md @@ -48,7 +48,7 @@ import bs58 from "bs58"; // 1) use build-in function let mintPubkey = await createMint( - connection, // conneciton + connection, // connection feePayer, // fee payer alice.publicKey, // mint authority alice.publicKey, // freeze authority (you can use `null` to disable it. when you disable it, you can't turn it on again) diff --git a/content/cookbook/tokens/set-update-token-authority.md b/content/cookbook/tokens/set-update-token-authority.md index d7ca156e1..032b64358 100644 --- a/content/cookbook/tokens/set-update-token-authority.md +++ b/content/cookbook/tokens/set-update-token-authority.md @@ -83,7 +83,7 @@ import bs58 from "bs58"; { let tx = new Transaction().add( createSetAuthorityInstruction( - mintPubkey, // mint acocunt || token account + mintPubkey, // mint account || token account alice.publicKey, // current auth AuthorityType.MintTokens, // authority type feePayer.publicKey, // new auth (you can pass `null` to close it) diff --git a/content/cookbook/tokens/transfer-tokens.md b/content/cookbook/tokens/transfer-tokens.md index 87a046660..29e120d34 100644 --- a/content/cookbook/tokens/transfer-tokens.md +++ b/content/cookbook/tokens/transfer-tokens.md @@ -60,7 +60,7 @@ import bs58 from "bs58"; mintPubkey, // mint tokenAccountYPubkey, // to (should be a token account) alice, // from's owner - 1e8, // amount, if your deciamls is 8, send 10^8 for 1 token + 1e8, // amount, if your decimals is 8, send 10^8 for 1 token 8, // decimals ); console.log(`txhash: ${txhash}`); @@ -76,7 +76,7 @@ import bs58 from "bs58"; mintPubkey, // mint tokenAccountYPubkey, // to (should be a token account) alice.publicKey, // from's owner - 1e8, // amount, if your deciamls is 8, send 10^8 for 1 token + 1e8, // amount, if your decimals is 8, send 10^8 for 1 token 8, // decimals ), ); diff --git a/content/cookbook/transactions/offline-transactions.md b/content/cookbook/transactions/offline-transactions.md index 3d95e4ca1..793f66d2c 100644 --- a/content/cookbook/transactions/offline-transactions.md +++ b/content/cookbook/transactions/offline-transactions.md @@ -22,7 +22,7 @@ import { import * as nacl from "tweetnacl"; import * as bs58 from "bs58"; -// to complete a offline transaction, I will seperate them into four steps +// to complete a offline transaction, I will separate them into four steps // 1. Create Transaction // 2. Sign Transaction // 3. Recover Transaction @@ -65,7 +65,7 @@ import * as bs58 from "bs58"; ); let aliceSignature = nacl.sign.detached(realDataNeedToSign, alice.secretKey); - // 3. Recover Tranasction + // 3. Recover Transaction // you can verify signatures before you recovering the transaction let verifyFeePayerSignatureResult = nacl.sign.detached.verify( @@ -83,7 +83,7 @@ import * as bs58 from "bs58"; console.log(`verify alice signature: ${verifyAliceSignatureResult}`); // there are two ways you can recover the tx - // 3.a Recover Tranasction (use populate then addSignauture) + // 3.a Recover Transaction (use populate then addSignature) { let recoverTx = Transaction.populate(Message.from(realDataNeedToSign)); recoverTx.addSignature(feePayer.publicKey, Buffer.from(feePayerSignature)); @@ -97,7 +97,7 @@ import * as bs58 from "bs58"; // or - // 3.b. Recover Tranasction (use populate with signature) + // 3.b. Recover Transaction (use populate with signature) { let recoverTx = Transaction.populate(Message.from(realDataNeedToSign), [ bs58.encode(feePayerSignature), diff --git a/content/courses/connecting-to-offchain-data/oracles.md b/content/courses/connecting-to-offchain-data/oracles.md index d00497335..53cd16797 100644 --- a/content/courses/connecting-to-offchain-data/oracles.md +++ b/content/courses/connecting-to-offchain-data/oracles.md @@ -1268,7 +1268,7 @@ describe("burry-escrow", () => { if (solPrice === null) { throw new Error("Aggregator holds no value"); } - // Although `SOL_USD_SWITCHBOARD_FEED` is not changing we are changing the unlockPrice in test as given below to simulate the escrow behaviour + // Although `SOL_USD_SWITCHBOARD_FEED` is not changing we are changing the unlockPrice in test as given below to simulate the escrow behavior const unlockPrice = solPrice.minus(PRICE_OFFSET).toNumber(); await createAndVerifyEscrow(unlockPrice); @@ -1332,7 +1332,7 @@ describe("burry-escrow", () => { if (solPrice === null) { throw new Error("Aggregator holds no value"); } - // Although `SOL_USD_SWITCHBOARD_FEED` is not changing we are changing the unlockPrice in test as given below to simulate the escrow behaviour + // Although `SOL_USD_SWITCHBOARD_FEED` is not changing we are changing the unlockPrice in test as given below to simulate the escrow behavior const unlockPrice = solPrice.plus(PRICE_OFFSET).toNumber(); await createAndVerifyEscrow(unlockPrice); }); diff --git a/content/courses/connecting-to-offchain-data/verifiable-randomness-functions.md b/content/courses/connecting-to-offchain-data/verifiable-randomness-functions.md index e868ee073..7f9eb3af1 100644 --- a/content/courses/connecting-to-offchain-data/verifiable-randomness-functions.md +++ b/content/courses/connecting-to-offchain-data/verifiable-randomness-functions.md @@ -199,7 +199,7 @@ Lastly, the `callback` field is where you define the callback instruction the Switchboard program should invoke once the randomness result has be verified. The `callback` field is of type -`[CallbackZC](https://github.com/switchboard-xyz/solana-sdk/blob/9dc3df8a5abe261e23d46d14f9e80a7032bb346c/rust/switchboard-solana/src/oracle_program/accounts/ecvrf.rs#L25)`. +[`CallbackZC`](https://github.com/switchboard-xyz/solana-sdk/blob/9dc3df8a5abe261e23d46d14f9e80a7032bb346c/rust/switchboard-solana/src/oracle_program/accounts/ecvrf.rs#L25). ```rust #[zero_copy(unsafe)] diff --git a/content/guides/getstarted/scaffold-nextjs-anchor.md b/content/guides/getstarted/scaffold-nextjs-anchor.md index 95729eb8d..6af833062 100644 --- a/content/guides/getstarted/scaffold-nextjs-anchor.md +++ b/content/guides/getstarted/scaffold-nextjs-anchor.md @@ -255,7 +255,7 @@ supports shared layouts, nested routing, loading states, and error handling. The `solana-provider.tsx` already has all the wallet features you need, It handles auto connects of Solana wallet easily, and you can move to multiple components of your web application with the wallet states managed. This NextJS -app is using `[@tanstack/react-query](`https://tanstack.com/query/latest)` to +app is using [`@tanstack/react-query`](https://tanstack.com/query/latest) to fetch, cache, synchronize, and update server stateĀ in your web applications easily. React-Query here is used for all the data fetching needs, like a hook for `useGetBalance` to get the balance of your wallet, `useTransferSol` to