Skip to content

docs: add common pitfalls section clarifying @ton/core vs @ton/ton imports#348

Open
spendollars wants to merge 1 commit intoton-org:developfrom
spendollars:docs/add-typescript-import-guide
Open

docs: add common pitfalls section clarifying @ton/core vs @ton/ton imports#348
spendollars wants to merge 1 commit intoton-org:developfrom
spendollars:docs/add-typescript-import-guide

Conversation

@spendollars
Copy link

What

Adds a Common pitfalls section to the README documenting the correct import packages for TON utilities.

Why

A very common source of confusion for developers starting with Blueprint is knowing which package exports which utility. In particular, internal() (for creating internal messages) must be imported from @ton/core, not @ton/ton — but this is not documented anywhere.

This causes silent runtime failures (TypeError: internal is not a function) that are hard to debug.

Changes

  • Added ## Common pitfalls section at the end of README.md
  • Includes a quick-reference table: @ton/core vs @ton/ton vs @ton/crypto
  • Includes ✅ correct and ❌ wrong code examples

Context

Found this issue while building TON Agent Platform, an open-source no-code AI agent platform on TON. Also opened a related issue in ton-org/ton-core: ton-org/ton-core#145

Clarifies which utilities come from @ton/core vs @ton/ton, which is
a frequent source of confusion (e.g. internal() message creator).
Includes a reference table and code examples.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant