-
Notifications
You must be signed in to change notification settings - Fork 362
Description
- 3629. Add descriptive alt text to transfer image
Set a descriptive alt on the ThemedImage (e.g., alt="TON transfer diagram") instead of alt="" because the image conveys information.
- 3630. Increase NFT forward amount to 0.01 TON
In 2-send-nft.ts, replace ".storeCoins(1)" with ".storeCoins(toNano('0.01'))" (ensure "import { toNano }") to use the typical 0.01 TON forward_amount recommended in the NFT docs.
- 3631. Clarify mnemonic replacement comment
Revise the comment to "Replace with your own 24-word mnemonic from your wallet app." for clarity.
- 3632. Clarify NFT address comment
Revise the comment to "Address of the NFT you created at https://ton-collection-edit.vercel.app/deploy-nft-single" for clarity.
- 3633. Use "Set up" in button label
Change the button label to "Set up development environment" to match usage on this page (href unchanged).
- 3634. Clarify 'interact on-chain' phrasing
Line 7 in ee42357
In this part of the guide, we will proceed with the deployment of previously developed smart contracts and cover interaction with them on-chain. |
Replace "cover interaction with them on-chain" with "cover how to interact with them on-chain".
- 3635. Complete 'verify the sender' phrase
Line 11 in ee42357
We already know that [address](/v3/documentation/smart-contracts/addresses/address) is a unique identifier of a `smart contract` on the network, used to send transactions and verify the sender upon receiving. However, we still haven't discussed how it's created. The common formula for a smart contract address looks like this: |
Replace "verify the sender upon receiving" with "verify the sender upon receipt".
- 3636. Format address formula as code
Line 13 in ee42357
***address = hash(state_init(code, data))*** |
Replace the emphasized formula with code formatting: address = hash(state_init(code, data))
.
- 3637. Use canonical state name 'nonexist'
Line 19 in ee42357
In TON, any address that doesn't have any data is considered in the `nonexistent` state. Nevertheless, when we created a wallet using the wallet app in the [Getting started](/v3/guidelines/quick-start/getting-started) section, we were still able to get the address of our **future** wallet smart contract from the wallet app before its deployment and examine it in the explorer. |
Replace "nonexistent" with the canonical term: "In TON, any address that doesn't have any data is considered in the nonexist
state."
- 3638. Use Title Case for step headings
Lines 55 to 128 in ee42357
### Step 1: update the deployment script | |
Deployment scripts rely on the same wrappers that you have used in testing scripts. We will use one common script to deploy both of the previously deployed smart contracts. Update `deployHelloWorld.ts` with this code: | |
```typescript title="/scripts/deployHelloWorld.ts" | |
// @version TypeScript 5.8.3 | |
import { toNano } from '@ton/core'; | |
import { HelloWorld } from '../wrappers/HelloWorld'; | |
import { compile, NetworkProvider } from '@ton/blueprint'; | |
export async function run(provider: NetworkProvider) { | |
const helloWorld = provider.open( | |
HelloWorld.createFromConfig( | |
{ | |
id: Math.floor(Math.random() * 10000), | |
ctxCounter: 0, | |
ctxCounterExt: 0n, | |
}, | |
await compile('HelloWorld') | |
) | |
); | |
await helloWorld.sendDeploy(provider.sender(), toNano('0.05')); | |
await provider.waitForDeploy(helloWorld.address); | |
console.log('ID', await helloWorld.getID()); | |
} | |
``` | |
### Step 2: run deploy script | |
You can run the script by entering the following command: | |
```bash | |
npx blueprint run deployHelloWorld | |
``` | |
### Step 3: choose network | |
After that, you will see an interactive menu allowing you to choose a network: | |
```bash | |
? Which network do you want to use? (Use arrow keys) | |
mainnet | |
❯ testnet | |
custom | |
``` | |
:::danger | |
Before deployment to the `Mainnet`, ensure that your smart contracts correspond to [Security measures](/v3/guidelines/smart-contracts/security/overview/). As we said before, the `HelloWorld` smart contract **doesn't**. | |
::: | |
### Step 4: choose wallet app | |
Next, choose the way to access your wallet. The easiest way to do that is using [TON Connect](/v3/guidelines/ton-connect/overview/) for the most popular wallet apps: `TonKeeper`, `MyTonWallet`, or `Tonhub`. | |
```bash | |
? Which wallet are you using? (Use arrow keys) | |
❯ TON Connect compatible mobile wallet (example: Tonkeeper) | |
Create a ton:// deep link | |
Mnemonic | |
? Choose your wallet (Use arrow keys) | |
❯ Tonkeeper | |
MyTonWallet | |
Tonhub | |
``` | |
Finally, scan the QR code in the terminal through your wallet app and connect the wallet. After you've done that for the first time in the project, this step will be skipped. | |
You will receive a transaction request in your wallet app each time your code requires currency for a transaction. | |
### Step 5: observe your smart contract in network |
Update step headings to Title Case for consistency, e.g., "Update the Deployment Script", "Run the Deploy Script", "Choose Network", "Choose Wallet App", "Observe Your Smart Contract on the Network".
- 3639. Correct statement about number of contracts deployed
Line 57 in ee42357
Deployment scripts rely on the same wrappers that you have used in testing scripts. We will use one common script to deploy both of the previously deployed smart contracts. Update `deployHelloWorld.ts` with this code: |
Replace "both of the previously deployed smart contracts" with "We will use one script to deploy the previously developed smart contract."
- 3640. Streamline wallet access wording
Line 110 in ee42357
Next, choose the way to access your wallet. The easiest way to do that is using [TON Connect](/v3/guidelines/ton-connect/overview/) for the most popular wallet apps: `TonKeeper`, `MyTonWallet`, or `Tonhub`. |
Change "choose the way to access your wallet. The easiest way to do that is using" to "choose how to access your wallet. The easiest way is to use".
- 3641. Standardize Tonkeeper capitalization
Lines 110 to 121 in ee42357
Next, choose the way to access your wallet. The easiest way to do that is using [TON Connect](/v3/guidelines/ton-connect/overview/) for the most popular wallet apps: `TonKeeper`, `MyTonWallet`, or `Tonhub`. | |
```bash | |
? Which wallet are you using? (Use arrow keys) | |
❯ TON Connect compatible mobile wallet (example: Tonkeeper) | |
Create a ton:// deep link | |
Mnemonic | |
? Choose your wallet (Use arrow keys) | |
❯ Tonkeeper | |
MyTonWallet | |
Tonhub |
Replace "TonKeeper" with "Tonkeeper" consistently.
- 3642. Fix preposition 'on the network'
Line 128 in ee42357
### Step 5: observe your smart contract in network |
Change "observe your smart contract in network" to "observe your smart contract on the network".
- 3643. Fix transactions link target
Line 137 in ee42357
**Congratulations!** Your custom `smart contract` is ready to execute `get methods` the same way as your wallet in the [Getting started](/v3/guidelines/quick-start/getting-started) section and execute `transactions` the same as in the [Blockchain interaction](/v3/guidelines/quick-start/blockchain-interaction/reading-from-network) section — consider reading it to understand how to interact with `smart contracts` off-chain if you haven't already. |
Update the "execute transactions" reference to point to /v3/guidelines/quick-start/blockchain-interaction/writing-to-network (and keep "get methods" pointing to the reading guide if mentioned).
- 3644. Point internal messages tip to correct doc
Lines 140 to 142 in ee42357
:::tip | |
Using `Blueprint` and wallet apps is not the only option. You can create a message with [state_init](/v3/documentation/smart-contracts/message-management/sending-messages#message-layout) by yourself. Moreover, you can do it even through a smart contract's [internal message](/v3/documentation/smart-contracts/message-management/sending-messages#message-layout). | |
::: |
Change the second tip link to /v3/documentation/smart-contracts/message-management/internal-messages instead of duplicating the message-layout anchor.
- 3645. Remove backticks from non-code terms and brands
Remove backticks around common nouns and brand names (e.g., smart contract, Mainnet, Testnet, get methods, transactions, wallet apps) and reserve code formatting for code, APIs, or identifiers.
- 3646. Fix summary phrasing for clarity
Line 8 in ee42357
> **Summary:** In previous steps, we modified our smart contract interaction with `storage`, `get methods`, and learned the basic smart contract development flow. |
Replace “we modified our smart contract interaction with storage
, get methods
, and learned the basic smart contract development flow.” with “we modified our smart contract to interact with storage and get methods, and learned the basic smart contract development flow.”.
- 3647. Add missing articles in parameter descriptions
Lines 36 to 39 in ee42357
- `my_balance` - smart-contract balance at the beginning of the transaction. | |
- `msg_value` - funds received with message. | |
- `in_msg_full` - `cell` containing "header" fields of the message. | |
- `in_msg_body` - [slice](/v3/documentation/smart-contracts/func/docs/types#atomic-types) containing payload of the message. |
Fix phrasing to “funds received with the message” and “containing the payload of the message”; apply the same corrections in the Tolk tab descriptions.
- 3648. Correct “pf” typo in Tolk parameter description
Line 48 in ee42357
- `msgBody` - [slice](/v3/documentation/smart-contracts/func/docs/types#atomic-types) containing payload pf the message. |
Change “containing payload pf the message.” to “containing the payload of the message.” in the Tolk signature bullet for msgBody.
- 3649. Use correct message cell variable names
Line 56 in ee42357
What we are specifically interested in is the source address of the message, which we can extract from the `msg_full` cell. By obtaining that address and comparing it to a stored one — we can conditionally allow access to crucial parts of our smart contract functionality. A common approach looks like this: |
Update the narrative to reference the correct identifiers per language: in FunC use in_msg_full; in Tolk use msgFull.
- 3650. FunC roles example: grammar, semicolons, function name, unreachable throw
Lines 68 to 83 in ee42357
;; check if message was send by owner | |
if (equal_slices_bits(sender_address, owner_address)) { | |
;;owner operations | |
return | |
} else if (equal_slices_bits(sender_address, other_role_address)){ | |
;;other role operations | |
return | |
} else { | |
;;anyone else operations | |
return | |
} | |
;;no known operation were obtained for presented role | |
;;0xffff is not standard exit code, but is standard practice among TON developers | |
throw(0xffff); | |
} |
In the “Actors and roles” FunC snippet, fix comment grammar/capitalization (“Check if the message was sent by the owner.”; “Owner operations”, “Other-role operations”, “Anyone-else operations”), change equal_slices_bits(...) to equal_slice_bits(...), add missing semicolons to all return statements, and remove the final unreachable throw (or move the throw into the else branch instead of returning).
- 3651. Tolk roles example: API/methods, equality, semicolons, throw syntax
Lines 88 to 107 in ee42357
// This is NOT a part of the project, just an example. | |
fun onInternalMessage(myBalance: int, msgValue: int, msgFull: cell, msgBody: slice) { | |
// Parse the sender address from in_msg_full | |
var cs: slice = msgFull.beginParse(); | |
val flags = cs.loadMessageFlags(); | |
var sender_address = cs~load_msg_address(); | |
if (isSliceBitsEqual(sender_address, owner_address)) { | |
// owner operations | |
return | |
} else if (isSliceBitsEqual(sender_address, other_role_address)){ | |
// other role operations | |
return | |
} else { | |
// anyone else operations | |
return | |
} | |
throw 0xffff; // if the message contains an op that is not known to this contract, we throw | |
} |
Replace FunC-style calls with Tolk methods: use val flags = cs.loadMessageFlags(); val senderAddress = cs.loadAddress(); compare with senderAddress.bitsEqual(ownerAddress/otherRoleAddress); add semicolons to return statements; and use throw 0xffff; (no parentheses), removing any final unreachable throw.
- 3652. Tolk operations example: fix variables, methods, constants, throw
Lines 154 to 175 in ee42357
fun onInternalMessage(myBalance: int, msgValue: int, msgFull: cell, msgBody: slice) { | |
// Step 1: Check if the message is empty | |
if (slice.isEndOfSlice()) { | |
return; // Nothing to do with empty messages | |
} | |
// Step 2: Extract the operation code | |
var op = in_msg_body~load_uint(32); | |
// Step 3-7: Handle the requested operation | |
if (op == op::increment) { | |
increment(); //call to specific operation handler | |
return; | |
} else if (op == op::decrement) { | |
decrement(); | |
// Just accept the money | |
return; | |
} | |
// Unknown operation | |
throw(0xffff); | |
} |
Use the correct parameter and methods (if (msgBody.isEndOfSlice()) { ... }; val op = msgBody.loadUint(32);), define constants as OP_INCREMENT/OP_DECREMENT and compare against them, add missing semicolons to returns, and use throw 0xffff; (no parentheses).
- 3653. Use “actor model” phrasing
Line 180 in ee42357
By combining both of these patterns, you can achieve a comprehensive description of your smart contract's systems, ensuring secure interaction between them and unleashing the full potential of the TON actors model. |
Change “actors model” to “actor model”.
- 3654. Use an em dash before “wallet”
Line 184 in ee42357
`External messages` are your only way of toggling smart contract logic from outside the blockchain. Usually, there is no need for implementation of them in smart contracts because, in most cases, you don't want external entry points to be accessible to anyone except you. If this is all the functionality that you want from the external section, the standard way is to delegate this responsibility to a separate actor - [wallet](/v3/documentation/smart-contracts/contracts-specs/wallet-contracts#basic-wallets), which is practically the main reason they were designed for. |
Replace the hyphen with an em dash: “a separate actor — [wallet]”.
- 3655. Remove code styling from “Mainnet”
Line 189 in ee42357
This implementation is **unsafe** and may lead to losing your contract funds. Don't deploy it to `Mainnet`, especially with a high smart contract balance. |
Change “Don’t deploy it to Mainnet
” to “Don’t deploy it to Mainnet”.
- 3656. Standardize Tolk filename casing
Line 231 in ee42357
```tolk title="/contracts/HelloWorld.tolk" |
Update the code block label from “/contracts/HelloWorld.tolk” to “/contracts/hello_world.tolk” to match earlier steps.
- 3657. Clarify operation name differences by language
Line 263 in ee42357
This function, upon receiving an external message, will increment our `ctx_counter_ext` and also send an internal message to the specified address with the `increase` operation. |
Note that operation identifiers differ between FunC (e.g., op::increase) and Tolk (e.g., OP_INCREASE) and ensure naming matches the surrounding examples in each language.
- 3658. Standardize “smart contract” terminology
Replace hyphenated “smart-contract” with “smart contract” consistently across the page.
- 3659. Use "Set up" (verb) in headings
Replace "Setup development environment" in the page title and any section headings with the verb phrase "Set up development environment."
- 3660. Remove code styling from product and language names in prose
Remove backticks around proper nouns in prose (e.g., Blueprint, FunC, Tolk, Tact) and use plain text or links instead.
- 3661. Fix Node.js install instructions to include macOS and neutral wording
Revise instructions to: "Install Node.js for your OS (Windows, macOS, or Linux) using the official installer or a package manager, then verify with the following commands."
- 3662. Pluralize "command" to "commands" before version checks
Change "execute the following command" to "execute the following commands" since two commands are shown.
- 3663. Add comma after introductory clause in transition sentence
Insert a comma: "Now that your environment is set up, choose a programming language …".
- 3664. Add Oxford comma in language list
Change "in FunC, Tolk or Tact" to "in FunC, Tolk, or Tact."
- 3665. Rephrase "follow the same paths" to "names and options"
Replace "follow the same paths as in this guide" with "follow the same names and options as in this guide" for clarity.
- 3666. Make JSX Button props use consistent quote style
Use a single JSX style for string literals across props, e.g., colorType="secondary" and sizeType="sm" consistently.
- 3667. Use a consistent import quote style
Standardize imports to one quote style within this file (e.g., use single quotes for all import paths).
- 3668. Change heading to "Choose a programming language"
Rename the section header from "Choose the programming language" to "Choose a programming language" for natural phrasing.
- 3669. Remove duplicate "Setup development environment" H2
Delete or rename the repeated H2 to a distinct title (e.g., "Set up your environment") to avoid redundant TOC entries.
- 3670. Add explicit Node.js/npm version requirement
State minimum versions and align with the canonical guidance, e.g., "Node.js v20+ and npm v10+ are required."
- 3671. Remove duplicate language selection messaging
Eliminate redundancy by keeping a single call to action—retain the final "Choose a programming language" section and make Step 2 a brief overview or remove it.
- 3672. Remove unverifiable learning time estimates
Delete subjective time claims (e.g., "estimated time to learn is 25 min") or replace with neutral phrasing like "short introductory guides."
- 3673. Align template naming with wizard wording
Update "Project template: a simple counter contract in FunC, Tolk, or Tact" to match the wizard phrasing, e.g., "Project template: A simple counter contract (Tolk)."
- 3674. Clarify whether npm install is required after project creation
Add a note: "If dependencies were not installed during project creation, run npm install before continuing."
- 3675. Clarify info callout lead-in to contextualize links
Rephrase the callout lead-in to "For lower-level workflows and manual deployment details:" so the linked pages are clearly relevant.
- 3676. Standardize Blueprint repository link to canonical org
Update any Blueprint repository links on this page to use the canonical URL (https://github.com/ton-org/blueprint) consistently.
- 3677. Remove or substantiate claim about combining languages
Delete the claim "and even combine smart contracts in different languages" unless a doc reference is added that confirms and explains this workflow.
- 3678. Add missing semicolon in import
Line 4 in ee42357
import Button from '@site/src/components/button' |
The import lacks a trailing semicolon; change to: import Button from '@site/src/components/button';
- 3679. Remove code styling from “Blueprint”
Line 14 in ee42357
Before we proceed to actual smart contract development, let's briefly describe the project structure and explain how to use the **`Blueprint`**. |
Replace the overstyled Blueprint
with plain text (or bold without backticks): Blueprint (or Blueprint).
- 3680. Use neutral code fence for project structure block
Line 24 in ee42357
```ls title="Project structure" |
Change the code fence language from ls to a neutral option for Prism, e.g.,
text title="Project structure" (or omit the language).
- 3681. Fix wrappers tree indentation
Lines 33 to 35 in ee42357
└── wrappers/ # TypeScript wrappers for contract interaction | |
├── HelloWorld.ts # Wrapper class for smart contract | |
└── HelloWorld.compile.ts # Script for contract compilation |
Ensure HelloWorld.ts and HelloWorld.compile.ts are listed under wrappers/ in the tree: └── wrappers/ ├── HelloWorld.ts └── HelloWorld.compile.ts
- 3682. Lowercase “blockchain” in “TON blockchain”
Line 43 in ee42357
This folder contains your smart contract source code written in one of the available programming languages used for TON Blockchain smart contract development. |
Change “TON Blockchain” to “TON blockchain” per style for the generic noun.
- 3683. Clarify network testing guidance and remove quotes
Line 51 in ee42357
This directory contains test files for your smart contracts. Testing contracts directly on the TON network is not the best option because deployment requires some amount of time and may lead to losing funds. This testing playground allows you to execute multiple smart contracts and even send messages between them in your **"local network"**. Tests are crucial for ensuring your smart contracts behave as expected before deployment to the network. |
Rewrite to: “Testing contracts directly on the TON network is discouraged because deployment takes time and could result in loss of funds,” and use plain text “local network” (no quotes/bold).
- 3684. Use plain, lowercase “wrapper classes”
Line 55 in ee42357
To interact with your smart contract off-chain, you need to serialize and deserialize messages sent to it. `Wrapper` classes are developed to mirror your smart contract implementation, making its functionality simple to use. |
Replace code-formatted/capitalized Wrapper
with plain, lowercase “wrapper classes”.
- 3685. Simplify the development steps intro
Line 60 in ee42357
Almost any smart contract project development consists of five simple steps: |
Change “Almost any smart contract project development consists of five simple steps:” to “Most smart contract projects follow five simple steps:”.
- 3686. Tighten phrasing: “using” not “by using”
Line 88 in ee42357
Also, you can always generate the same structure for another smart contract if, for example, you want to create multiple contracts interacting with each other by using the following command: |
Replace “by using the following command:” with “using the following command:”.
- 3687. Use canonical address state term “nonexist”
Replace “nonexistent” with “nonexist,” and if a definition is given, state that it means the address has no code, data, and balance.
- 3688. Standardize storage field to lowercase id
Remove references to ctxID/ID and standardize the storage field and getters to lowercase id (e.g., getId) to match the Tact HelloWorld.
- 3689. Correct phrasing about number of contracts
Change “both of the previously deployed smart contracts” to “one script to deploy the previously developed HelloWorld smart contract,” or explicitly name both if two are intended.
- 3690. Remove unused compile import in deploy script
In the deployHelloWorld.ts snippet, remove compile from the @ton/blueprint imports or use it meaningfully.
- 3691. Standardize brand casing to Tonkeeper
Replace “TonKeeper” (and variants) with the correct brand form “Tonkeeper” throughout.
- 3692. Fix preposition in Step 5 heading
Change “observe your smart contract in network” to “observe your smart contract on the network.”
- 3693. Relabel interactive prompt code blocks
Change code fences showing interactive network/wallet selection menus from bash to text (or no language), since they are prompts, not shell commands.
- 3694. Render address formula as inline code
Replace the bold-italic formula with inline code: address = hash(state_init(code, data))
.
- 3695. Complete the “verify the sender” phrase
Replace “verify the sender upon receiving” with “verify the sender upon receiving a message” (or “upon receipt”).
- 3696. Clarify ambiguous “it” reference
Replace “consider reading it” with “consider reading those sections” or name the specific section to avoid ambiguity.
- 3697. Capitalize proper nouns (GitHub, By Example)
Change “Tact github repo” to “Tact GitHub repo” and “Tact by example” to “Tact by Example.”
- 3698. Fix link targets for message references
Keep state_init linked to the message layout anchor and link “internal message” to the message types section (e.g., /sending-messages#types-of-messages) instead of pointing both to the same anchor.
- 3699. Remove unused Tabs/TabItem imports
Lines 2 to 3 in ee42357
import Tabs from '@theme/Tabs'; | |
import TabItem from '@theme/TabItem'; |
Tabs and TabItem are imported but never used; remove these imports to eliminate lint warnings and reduce bundle size.
- 3700. Fix 'self reference' casing and article
Line 78 in ee42357
A contract may store its state variables as follows. They may be accessed with [`Self reference`](https://docs.tact-lang.org/book/contracts/#self) |
Replace “They may be accessed with Self reference” with “They may be accessed with the self
reference” (same link), using lower-case self and adding the article.
- 3701. Clarify empty-body receive sentence
Line 110 in ee42357
For accepting messages with empty body you can add `receive` function with no arguments: |
Change “For accepting messages with empty body you can add receive
function with no arguments:” to “For messages with an empty body, you can add a receive
function with no arguments:”.
- 3702. Add semicolon in empty-body receive example
Lines 112 to 115 in ee42357
```tact title="/contracts/hello_world.tact" | |
receive() { | |
cashback(sender()) | |
} |
Add the missing semicolon after cashback(sender()); in the empty-body receive() example.
- 3703. Clarify getter-call restriction grammar
Lines 122 to 124 in ee42357
:::note | |
Get function cannot be called from another contract. | |
::: |
Change “Get function cannot be called from another contract.” to “Getter functions cannot be called from another contract.”
- 3704. Fix typo 'defenition' to 'definition'
Line 141 in ee42357
// Contract defenition |
Correct the comment spelling from “Contract defenition” to “Contract definition”.
- 3705. Add semicolon in contract receive
Lines 154 to 157 in ee42357
// default(null) receive for deploy | |
receive() { | |
cashback(sender()) | |
} |
In the complete contract snippet, add the missing semicolon after cashback(sender()); in the default receive().
- 3706. Align 'forward remaining value back' comment
Lines 163 to 165 in ee42357
// Notify the caller that the receiver was executed and forward remaining value back | |
self.notify("Cashback".asComment()); | |
} |
Remove the misleading “and forward remaining value back” from the comment, or add an explicit cashback/send line to match the comment.
- 3707. Hyphenate 'off-chain' in comment
Line 167 in ee42357
// getter function to be called offchain |
Change “// getter function to be called offchain” to “// getter function to be called off-chain”.
- 3708. Add article in build-script instruction
Lines 178 to 182 in ee42357
Verify that smart contract code is correct by running build script: | |
```bash | |
npx blueprint build | |
``` |
Change to “Verify that the smart contract code is correct by running the build script:”.
- 3709. Standardize Step 3 heading style
Lines 198 to 210 in ee42357
## Step 2: update wrapper | |
After building your contract, Tact automatically generates a special wrapper file. This [wrapper]((https://docs.tact-lang.org/book/compile/#wrap-ts)) simplifies interaction with your contract from TypeScript, such as calling its methods or sending messages. | |
In the wrapper file, you'll find this line of code: | |
```typescript title="/wrappers/HelloWorld.ts" | |
export * from '../build/HelloWorld/tact_HelloWorld'; | |
``` | |
This code exports everything inside the `tact_HelloWorld.ts` file in the build folder, making it available for use in other files. | |
## Step 3: updating tests |
Change the heading from “Step 3: updating tests” to “Step 3: update tests” to match the imperative style used in Step 2.
- 3710. Fix broken wrapper link
Line 200 in ee42357
After building your contract, Tact automatically generates a special wrapper file. This [wrapper]((https://docs.tact-lang.org/book/compile/#wrap-ts)) simplifies interaction with your contract from TypeScript, such as calling its methods or sending messages. |
Correct the link formatting from “wrapper” to “wrapper”.
- 3711. Add article in test-script instruction
Lines 291 to 295 in ee42357
Don't forget to verify the example is correct by running test script: | |
```bash | |
npx blueprint test | |
``` |
Change to “Don’t forget to verify the example is correct by running the test script:”.
- 3712. Standardize "get methods" term formatting
Use consistent non-hyphenated, code-formatted "get methods": replace "get-method" and "get methods" with "get methods
" and leave existing code-formatted instances as-is.
- 3713. Remove comma before "unless"
Delete the comma in “Don’t worry, sharing your address is totally safe, unless you don’t want it to be associated with you.” so it reads “Don’t worry, sharing your address is totally safe unless you don’t want it to be associated with you.”
- 3714. Add descriptive alt text to ThemedImage
Replace the empty alt attribute (alt="") under “Creating a wallet” with a concise description, e.g., alt="Tonkeeper UI showing Testnet account creation".
- 3715. Normalize address state term to
nonexist
Use the canonical code term nonexist
(lowercase) in lists/code (fix “Nonexist
” and “nonexisting
”), and use “nonexistent” only in explanatory prose.
- 3716. Use "Toncoin" for currency unit
Replace “TON” used as the currency (e.g., “try sending some TON between them”) with “Toncoin” (“try sending some Toncoin between them”).
- 3717. Simplify Blueprint sentence and remove italics
Change “Set up a development environment using the Blueprint for the smart contract development.” to “Set up a development environment using Blueprint for smart contract development.”
- 3718. Remove code formatting from "explorer"
Change the common noun formatted as code (“using the explorer
”) to plain text (“using the explorer”).
- 3719. Use consistent bold syntax for time estimate
Change “30 minutes” to “30 minutes” to match the page’s bold formatting style.
- 3720. Fix preposition: "on your address" → "to your address"
Update “until you receive funds on your address and try to make your first transaction” to “until you receive funds to your address and try to make your first transaction.”
- 3721. Align heading capitalization style
Choose a single capitalization style for all headings and apply it consistently; use sentence case across the page to match the H1 “Getting started.”
- 3722. Prefer "on TON Blockchain" phrasing
Revise “Start writing smart contracts using the FunC, Tolk, and Tact programming languages in TON.” to “Start writing smart contracts using the FunC, Tolk, and Tact programming languages on TON Blockchain.”
- 3723. Fix page title grammar
# Fees calculation |
Change the H1 to "Fee calculation" (singular) instead of "Fees calculation".
- 3724. Fix broken intro anchor to “Elements of the transaction fee”
When your contract begins processing an incoming message, you should verify the number of TONs attached to the message to ensure it is sufficient to cover [all types of fees](/v3/documentation/smart-contracts/transaction-fees/fees#elements-of-transaction-fee). To achieve this, you need to calculate (or predict) the fee for the current transaction. |
Update the link to /v3/documentation/smart-contracts/transaction-fees/fees#elements-of-the-transaction-fee so it matches the target heading.
- 3725. Use correct currency phrasing in intro
When your contract begins processing an incoming message, you should verify the number of TONs attached to the message to ensure it is sufficient to cover [all types of fees](/v3/documentation/smart-contracts/transaction-fees/fees#elements-of-transaction-fee). To achieve this, you need to calculate (or predict) the fee for the current transaction. |
Replace “verify the number of TONs attached” with “verify the amount of Toncoin attached”.
- 3726. Update “TVM instruction page” link text and target
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 11 to 13 in ee42357
:::info opcodes | |
For a comprehensive list of TVM opcodes, including those mentioned below, refer to the [TVM instruction page](/v3/documentation/tvm/instructions). | |
::: |
Change the link text to “TVM instructions” and point it to /v3/documentation/tvm/tvm-overview#tvm-instructions (the existing page).
- 3727. Remove code formatting from general term
In short, `storage fees` are the costs of storing a smart contract on the blockchain. You pay for every second the smart contract remains stored on the blockchain. |
Replace the inline code-styled “storage fees
” with plain text “storage fees”.
- 3728. Add missing
seconds
to GETSTORAGEFEE parameters table
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 21 to 27 in ee42357
Use the `GETSTORAGEFEE` opcode with the following parameters: | |
| Param name | Description | | |
| :--------- | :------------------------------------------------------ | | |
| cells | Number of contract cells | | |
| bits | Number of contract bits | | |
| is_mc | True if the source or destination is in the MasterChain | |
Insert a seconds
row (duration in seconds for the estimate) and keep the boolean named is_mc
for consistency.
- 3729. Rename boolean to
is_mc
in GETSTORAGEFEE signature
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 37 to 39 in ee42357
```func | |
int get_storage_fee(int workchain, int seconds, int bits, int cells) asm(cells bits seconds workchain) "GETSTORAGEFEE"; | |
``` |
Change the FunC declaration to use is_mc
and keep stack order as asm(cells bits seconds is_mc), e.g., int get_storage_fee(int is_mc, int seconds, int bits, int cells) asm(cells bits seconds is_mc) "GETSTORAGEFEE";
- 3730. Remove misleading stdlib availability note
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 43 to 47 in ee42357
```func | |
;; functions from func stdlib (not available on mainnet) | |
() raw_reserve(int amount, int mode) impure asm "RAWRESERVE"; | |
int get_storage_fee(int workchain, int seconds, int bits, int cells) asm(cells bits seconds workchain) "GETSTORAGEFEE"; | |
int my_storage_due() asm "DUEPAYMENT"; |
Delete “(not available on mainnet)” and rephrase to “functions from the FunC stdlib”.
- 3731. Use “nanotons” unit consistently
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 50 to 56 in ee42357
;;; Creates an output action which reserves exactly x nanoTONs (if y = 0). | |
const int RESERVE_REGULAR = 0; | |
;;; Creates an output action which reserves at most x nanoTONs (if y = 2). | |
;;; Bit +2 in y ensures the external action does not fail if the specified amount cannot be reserved. Instead, it reserves all remaining balance. | |
const int RESERVE_AT_MOST = 2; | |
;;; In the case of action failure, the transaction is bounced. No effect if RESERVE_AT_MOST (+2) is used. TVM UPGRADE 2023-07. [v3/documentation/tvm/changelog/tvm-upgrade-2023-07#sending-messages](https://ton.org/docs/#/tvm/changelog/tvm-upgrade-2023-07#sending-messages) | |
const int RESERVE_BOUNCE_ON_ACTION_FAIL = 16; |
Replace “nanoTONs” with “nanotons” in all occurrences in this section.
- 3732. Replace outdated absolute link with repo-relative link
;;; In the case of action failure, the transaction is bounced. No effect if RESERVE_AT_MOST (+2) is used. TVM UPGRADE 2023-07. [v3/documentation/tvm/changelog/tvm-upgrade-2023-07#sending-messages](https://ton.org/docs/#/tvm/changelog/tvm-upgrade-2023-07#sending-messages) |
Change https://ton.org/docs/#/tvm/changelog/tvm-upgrade-2023-07#sending-messages to /v3/documentation/tvm/changelog/tvm-upgrade-2023-07#sending-messages.
- 3733. Fix example: use passed balance and align variable names
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 58 to 62 in ee42357
() calculate_and_reserve_at_most_storage_fee(int balance, int msg_value, int workchain, int seconds, int bits, int cells) inline { | |
int on_balance_before_msg = my_ton_balance - msg_value; | |
int min_storage_fee = get_storage_fee(workchain, seconds, bits, cells); ;; You can hardcode this value if the contract code will not be updated. | |
raw_reserve(max(on_balance_before_msg, min_storage_fee + my_storage_due()), RESERVE_AT_MOST); | |
} |
Use the balance
parameter (e.g., int ton_balance_before_msg = balance - msg_value;) instead of an undefined my_ton_balance
, and rename on_balance_before_msg
to ton_balance_before_msg
(or balance_before_msg
); also update nearby prose to refer to min_storage_fee
(not storage_fee
) to match the snippet.
- 3734. Rename boolean to
is_mc
in GETGASFEE signature
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 80 to 82 in ee42357
```func | |
int get_compute_fee(int workchain, int gas_used) asm(gas_used workchain) "GETGASFEE"; | |
``` |
Change the FunC declaration to use is_mc
and stack order asm(gas_used is_mc), e.g., int get_compute_fee(int is_mc, int gas_used) asm(gas_used is_mc) "GETGASFEE";
- 3735. Fix currency casing in comment
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 118 to 123 in ee42357
expect(sendResult.transactions).toHaveTransaction({ | |
// excesses | |
from: notDeployerJettonWallet.address, | |
to: deployer.address, | |
}); | |
/* |
Change the inline comment “// tons” to “// TON”.
- 3736. Fix TypeScript snippet: declare variable and use gasUsed
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 166 to 167 in ee42357
send_gas_fee = printTxGasStats("Jetton transfer", transferTx); | |
``` |
Declare the variable and return gas used, e.g., const sendGasUsed = printTxGasStats(...).txComputed.gasUsed; and use camelCase naming.
- 3737. Correct SENDMSG table and clarify +1024 behavior
ton-docs/docs/v3/guidelines/smart-contracts/fee-calculation.mdx
Lines 208 to 214 in ee42357
If even `GETORIGINALFWDFEE` cannot be used, one more option exists. Use the `SENDMSG` opcode with the following parameters: | |
| Param name | Description | | |
| :--------- | :-------------- | | |
| cells | Number of cells | | |
| mode | Message mode | | |
Update the parameters to msg
(serialized message cell) and mode
(message mode), and clarify that with flag +1024 it returns the estimated fee without creating an output action.
- 3738. Clarify
is_mc
meaning for fee opcodes
Rephrase the is_mc
descriptions for GETSTORAGEFEE/GETGASFEE to indicate whether execution is in the masterchain (true) or basechain (false), rather than referring to source/destination of a message.
- 3739. Simplify prerequisite note
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 5 to 7 in ee42357
:::note | |
To fully benefit from this content, readers must understand the [FunC programming language](/v3/documentation/smart-contracts/func/overview/) on the TON Blockchain. This knowledge is crucial for grasping the information presented here. | |
::: |
Replace the note with a single sentence: “This guide assumes familiarity with the FunC language.” keeping the existing link unchanged.
- 3740. Fix FunC example indentation
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 23 to 27 in ee42357
```func | |
int get_balance() method_id { | |
return get_data().begin_parse().preload_uint(64); | |
} | |
``` |
Indent the return line in the get_balance() example by one space to match the page’s code style.
- 3741. Add external cross-links for Jettons and NFTs
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 29 to 37 in ee42357
2. **Aggregate data retrieval**: Another common method is to create methods that gather multiple pieces of data from a contract's state in one call. This is useful when specific data points are often used together. You can see this approach frequently in [Jetton](#jettons) and [NFT](#nfts) contracts. | |
Example: | |
```func | |
(int, slice, slice, cell) get_wallet_data() method_id { | |
return load_data(); | |
} | |
``` |
Supplement the in-page anchors with secondary links to the overviews: docs/v3/guidelines/dapps/asset-processing/jettons.mdx#overview and docs/v3/guidelines/dapps/asset-processing/nft-processing/nfts.mdx#overview.
- 3742. Correct seqno description
Returns the transaction's sequence number within a specific wallet. This method is primarily used for [replay protection](/v3/guidelines/smart-contracts/howto/wallet#replay-protection---seqno). |
Replace the sentence with: “Returns the wallet’s current outbound message sequence number (seqno).”
- 3743. Rephrase get_public_key description
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 87 to 96 in ee42357
#### get_public_key() | |
```func | |
int get_public_key() method_id { | |
var cs = get_data().begin_parse().skip_bits(64); | |
return cs.preload_uint(256); | |
} | |
``` | |
This method retrieves the public key associated with the wallet. |
Change the prose to: “Returns the stored public key.”
- 3744. Standardize Jetton wallet data labels
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 108 to 114 in ee42357
This method returns the complete set of data associated with a jetton wallet: | |
- (int) balance | |
- (slice) owner_address | |
- (slice) jetton_master_address | |
- (cell) jetton_wallet_code | |
Align bullet labels with the jetton docs using “owner address”, “jetton master (minter) address”, and “jetton_wallet_code” (or use code-style names consistently).
- 3745. Make bullet punctuation consistent
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 110 to 113 in ee42357
- (int) balance | |
- (slice) owner_address | |
- (slice) jetton_master_address | |
- (cell) jetton_wallet_code |
Ensure all items in this bullet list use no terminal periods to match the page’s style.
- 3746. Document mintable field in get_jetton_data
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 115 to 125 in ee42357
#### get_jetton_data() | |
```func | |
(int, int, slice, cell, cell) get_jetton_data() method_id { | |
(int total_supply, slice admin_address, cell content, cell jetton_wallet_code) = load_data(); | |
return (total_supply, -1, admin_address, content, jetton_wallet_code); | |
} | |
``` | |
Returns data of a jetton master, including its total supply, the address of its admin, the content of the jetton, and its wallet code. | |
Update the description to list all five tuple fields and explain the mintable flag (−1 mintable, 0 non‑mintable), e.g., “Returns total supply, mintable flag, admin address, content, and jetton wallet code.”
- 3747. Clarify get_collection_data ordering
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 152 to 160 in ee42357
```func | |
(int, cell, slice) get_collection_data() method_id { | |
var (owner_address, next_item_index, content, _, _) = load_data(); | |
slice cs = content.begin_parse(); | |
return (next_item_index, cs~load_ref(), owner_address); | |
} | |
``` | |
Returns the data of an NFT collection, including the index of the next item available for minting, the content of the collection, and the owner's address. |
Add a brief note that the returned tuple order is (next_item_index, collection_content, owner_address) even if local variable naming order differs.
- 3748. Explain workchain() helper
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 165 to 169 in ee42357
slice get_nft_address_by_index(int index) method_id { | |
var (_, _, _, nft_item_code, _) = load_data(); | |
cell state_init = calculate_nft_item_state_init(index, nft_item_code); | |
return calculate_nft_item_address(workchain(), state_init); | |
} |
Add a note that workchain() returns the current workchain ID and link to docs/v3/documentation/smart-contracts/func/cookbook.mdx#generate-an-internal-address.
- 3749. Fix link text for NFT content reference
Given an index and [individual NFT content](#get_nft_data), this method fetches and returns the NFT's combined common and individual content. |
Change the link text to “get_nft_data()” to match the target anchor.
- 3750. Capitalize JavaScript correctly
We will use Javascript libraries and tools for the examples below: |
Replace “Javascript” with “JavaScript,” e.g., “We will use JavaScript libraries and tools for the examples below:”.
- 3751. Add Testnet endpoint hint
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 239 to 257 in ee42357
```ts | |
import { TonClient } from "@ton/ton"; | |
import { Address } from "@ton/core"; | |
async function main() { | |
// Create Client | |
const client = new TonClient({ | |
endpoint: "https://toncenter.com/api/v2/jsonRPC", | |
}); | |
// Call get method | |
const result = await client.runMethod( | |
Address.parse("EQD4eA1SdQOivBbTczzElFmfiKu4SXNL4S29TReQwzzr_70k"), | |
"get_total" | |
); | |
const total = result.stack.readNumber(); | |
console.log("Total:", total); | |
} | |
Add a comment in the code sample showing the Testnet endpoint: https://testnet.toncenter.com/api/v2/jsonRPC.
- 3752. Update Sandbox repository link
We can use the [Sandbox](https://github.com/ton-community/sandbox/) to test smart contracts, which is installed by default in new Blueprint projects. |
Change the link to https://github.com/ton-org/sandbox/ for consistency.
- 3753. Replace “pure functions” with “deterministic”
Lastly, smart contracts in TON are designed to be pure functions: they will always produce the same output for the same input. This principle allows for straightforward consensus during message processing. Introducing runtime acquisition of arbitrary, dynamically changing data would break this deterministic property. |
Rephrase to: “Smart contracts in TON are deterministic: for the same state and input, they produce the same output.”
- 3754. Link to sending messages page
.store_uint(0, 107) ;; default message headers (see sending messages page) |
Add a link for “default message headers (see sending messages page)” to /v3/documentation/smart-contracts/message-management/sending-messages.
- 3755. Clarify get methods cannot mutate state
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 364 to 368 in ee42357
## Common pitfalls and how to avoid them | |
1. **Misuse of get methods**: As mentioned earlier, get methods are designed to return data from the contract's state and are not meant to change the contract's state. Attempting to alter the contract's state within a get method will not do it. | |
2. **Ignoring return types**: Every get method must have a clearly defined return type that matches the retrieved data. If a method is expected to return a specific type of data, ensure that all execution paths within the method return this type. Inconsistent return types should be avoided, as they can lead to errors and complications when interacting with the contract. |
Replace the awkward sentence with: “Get methods must not change state; any attempted state changes have no effect.”
- 3756. Add ‘See also’ link to storage/get-methods tutorial
ton-docs/docs/v3/guidelines/smart-contracts/get-methods.mdx
Lines 376 to 378 in ee42357
## See also | |
- [Writing tests examples](/v3/guidelines/smart-contracts/testing/writing-test-examples) | |
Augment the See also section with a link to docs/v3/guidelines/quick-start/developing-smart-contracts/func-tolk-folder/storage-and-get-methods/.
- 3757. Hyphenate “double-spend” consistently
Standardize all occurrences to “double‑spend” (including headings and inline identifiers), replacing “double spend” and “double_spend” when referring to the contract.
- 3758. Fix fragment in “Double-spend” section
Rewrite the fragment to a complete sentence: “Receives a message; if already used, it bounces; otherwise, it forwards the message.”
- 3759. Tighten jetton subsection phrasing and “out of scope”
Replace “Jetton wallet, where the tokens will be sent from by the distributor.” with “Jetton wallet from which the distributor sends the tokens.” and change “out of the scope” to “out of scope for this article.”
- 3760. Add period to “Fee wallet” sentence
Add a terminal period to the sentence “Any kind of wallet contract.”
- 3761. Replace informal “Ok” opening
Change “Ok, we got something going, but what about shard optimizations?” to “Okay, we have something going, but what about shard optimizations?”
- 3762. Clarify shard definition wording
Replace “A shard is a 4-bit address prefix” with “Shard selection (the shard index) is determined by the first 4 bits of the contract address hash (the shard prefix).”
- 3763. Capitalize “Merkle” terms
Capitalize “Merkle” in phrases like “Merkle proof” and “Merkle root,” including link text and narrative.
- 3764. Label TL‑B code blocks and fix field formatting
Add the language tag “tlb” to TL‑B schema code fences and normalize field formatting (e.g., “addr_hash:uint256” with no spaces around colons).
- 3765. Remove editorial artifact sentence
Delete the sentence “Here’s the improved and more polished version of your text:”.
- 3766. Remove “?” to mark optionality in tuple
Replace “StateInit (distributor_address, user_address?)” with “StateInit (distributor_address, optional user_address)” and explain optionality in prose rather than via a question mark.
- 3767. Clarify V3 verification phrasing
Replace “verifies the sending double spend
address” with “verifies the double‑spend
contract address by checking the StateInit (distributor_address, index)”.
- 3768. Remove casual interjections
Remove “LGTM.” and the aside “(Has this ever happened in real life?)” to maintain a professional tone.
- 3769. Standardize lowercase “jetton” in running text
Use lowercase “jetton” in sentences (e.g., “jetton wallet”), reserving capitalization for headings or proper names.
- 3770. Expand abbreviations in summary chains
Expand “double_spend -> dist -> dist_jetton” to “double‑spend -> distributor -> distributor jetton wallet” and similarly expand “dist_jetton -> user_jetton -> user_wallet” to full names without underscores.
- 3771. Use mass noun “jettons” (no article)
Prefer “releases jettons” (no definite article) in running text.
- 3772. Use TL‑B term “StateInit”
Replace “state init” with the TL‑B term “StateInit” wherever it refers to the structure (e.g., in summaries and V2/V3 steps).
- 3773. Align “claim wallet” with “fee wallet”
Change “at least one claim wallet” in the introduction to “at least one fee wallet” to match later usage and field names.
- 3774. Make address derivation wording precise
Replace “the contract address is defined by its state” with “a contract address is derived from the hash of its initial code and initial data (StateInit)”.
- 3775. Use canonical TL‑B casing “Hashmap”
Replace “HashMap” with “Hashmap” (e.g., “Hashmap 64”, “Hashmap 256”) to match TL‑B type casing.
- 3776. Verify key width “Hashmap 267”
Confirm whether “Hashmap 267” is intentional; if it is a placeholder, change to “Hashmap 256,” or otherwise add a brief note explaining the nonstandard width.
- 3777. Remove placeholder “naive art” lines
Delete placeholders like “NAIVE ART AHEAD!”, “More naive art”, and “A bit more art” or replace them with actual figures and captions.
- 3778. Avoid unsupported numeric claim
Replace the unsourced “87% probability” statement with a qualitative phrase (e.g., “with high probability”) or add a citation if a precise probability is documented.
- 3779. Clarify which loop is redundant
Replace “Looks like a loop is redundant here.” with a specific statement (e.g., “The round‑trip from the double‑spend contract back to the distributor is unnecessary; use a linear design.”).
- 3780. Standardize "macOS" capitalization
Replace all instances of "MacOS" with "macOS" in headings and prose.
- 3781. Fix wording: "terminal of" → "terminal on"
Change “Then run the following in a terminal of Linux or MacOS:” to “Then run the following in a terminal on Linux or macOS:”.
- 3782. Prepend sudo to Ubuntu apt update
In the Ubuntu section, change apt update
to sudo apt update
to match typical non-root usage.
- 3783. Make ton/ton-build paths consistent
Ensure the documented layout matches the commands by adding cd ~
before git clone
, using mkdir -p ~/ton-build && cd ~/ton-build
, and running cmake ... ../ton
.
- 3784. Add macOS build step after CMake
After the CMake configure command, add a build invocation, e.g., cmake --build . -j$(sysctl -n hw.ncpu)
(or ninja -j$(sysctl -n hw.ncpu)
if using Ninja).
- 3785. Add colons before code blocks
End sentences that introduce code blocks with colons, e.g., “Use the newly installed clang:”, “Relink OpenSSL 3.0:”, “Now you can compile TON:”.
- 3786. Remove leading spaces in macOS code blocks
Delete the unnecessary two-space indent before commands in macOS code blocks to avoid copy-paste issues.
- 3787. Fix low-memory note grammar and units
Change “1 Gb” to “1 GB” and “a swap partitions” to “a swap partition”.
- 3788. Use "writable" instead of "writeable"
Replace “writeable” with the standard spelling “writable”.
- 3789. Use "Lite Client" consistently
Use “Lite Client” for the tool name in headings and prose (keep lowercase only for the binary path if shown).
- 3790. Lowercase heading: "tonlib-cli"
Change the section heading “Tonlib-cli” to “tonlib-cli” to match the tool name.
- 3791. Use three-dot ellipsis in Fift example
Change “..” to “...” in the Fift example to indicate omitted parameters.
- 3792. Format bare URLs as Markdown links
Convert bare URLs to Markdown links, e.g., “available at the GitHub repository”; do similarly in the config download section.
- 3793. Clarify global config download sentence
Rephrase to “For tools like the Lite Client, download the global network config.” for clarity and consistent capitalization.
- 3794. Include git in prerequisites and Ubuntu install
Add git
to the prerequisites list and include it in the Ubuntu install command (sudo apt install ... git
).
- 3795. Replace nproc in cross-platform example
In the mixed Linux/macOS step, avoid Linux-only nproc
; either scope the parallel build flag to Linux or provide a macOS alternative (e.g., -j$(sysctl -n hw.ncpu)
or a fixed -jN
).
- 3796. Create and enter build dir in macOS section before CMake
Before invoking CMake, add mkdir -p ~/ton-build && cd ~/ton-build
and configure with cmake ... ../ton
to avoid running from the lz4
directory.
- 3797. Note Homebrew prefix may differ on Intel Macs
Add a note that Homebrew may be under /usr/local
on Intel Macs; adjust paths like /opt/homebrew/opt/llvm@16/...
accordingly.
- 3798. Use canonical ton.org URLs for global configs
Replace https://ton-blockchain.github.io/global.config.json
and its testnet variant with https://ton.org/global-config.json
and https://ton.org/testnet-global.config.json
to align with other pages.
- 3799. Clarify “autobuild scripts” link label
Change the link text “autobuild scripts” to “GitHub Actions workflows for automatic builds” (keep the same target) to better describe the link.
- 3800. Replace “swap partition” with “swap file/space”
Replace references to partitions with file-based swap to match the procedure: L9 “create swap partitions.” → “create swap space (using a swap file).”; L22 “create a 4GB swap partition:” → “create a 4 GiB swap file:”; L25 comment → “# Create swap directory” (if creating /var/cache/swap); L46 “Remove swap partition:” → “Remove swap file:”.
- 3801. Standardize size units and spacing
Use consistent binary units with spaces and align with dd semantics: “< 1 GB” → “< 1 GiB” (L9), “4GB” → “4 GiB” (L22), “64MB” → “64 MiB” and “(64 MiB blocks × 64)” (L28 and its comment).