Skip to content

[Porta] fix llm.txt generation #7500

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 2, 2025
Merged

Conversation

joaquim-verges
Copy link
Member

@joaquim-verges joaquim-verges commented Jul 2, 2025


PR-Codex overview

This PR primarily focuses on enhancing the TypeScript documentation and updating the fetchTypeScriptDoc function to improve type safety. It also introduces new UI components and updates existing ones in the documentation.

Detailed summary

  • Added TransformArg type to improve type safety in fetchTypeScriptDoc.
  • Updated fetchTypeScriptDoc to correctly cast doc.default.
  • Introduced new widgets: BuyWidget, CheckoutWidget, TransactionWidget.
  • Updated documentation for existing and new widgets.
  • Removed the Buy Crypto section and integrated relevant functions elsewhere.
  • Added new hooks: useBlockNumber, useBridgeRoutes.
  • Updated ERC4337 and added new ERC7702 section.
  • Enhanced server wallet functionalities and added transaction search capabilities.

The following files were skipped due to too many changes: apps/portal/public/llms-full.txt

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Summary by CodeRabbit

  • Documentation
    • Reorganized and clarified documentation for Universal Bridge and Buy Crypto features.
    • Added a new "Universal Bridge" section with three new widget references for purchasing tokens.
    • Updated and consolidated buy-related functions and hooks into new sections for better navigation.
    • Added documentation for new ERC7702 methods and Universal Bridge Onramp functionality.
    • Documented new server wallet management and transaction search features.
    • Marked deprecated features and provided guidance on updated usage.

@joaquim-verges joaquim-verges requested review from a team as code owners July 2, 2025 05:27
Copy link

changeset-bot bot commented Jul 2, 2025

⚠️ No Changeset found

Latest commit: b767189

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

vercel bot commented Jul 2, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docs-v2 ❌ Failed (Inspect) Jul 2, 2025 5:37am
4 Skipped Deployments
Name Status Preview Comments Updated (UTC)
nebula ⬜️ Skipped (Inspect) Jul 2, 2025 5:37am
thirdweb_playground ⬜️ Skipped (Inspect) Jul 2, 2025 5:37am
thirdweb-www ⬜️ Skipped (Inspect) Jul 2, 2025 5:37am
wallet-ui ⬜️ Skipped (Inspect) Jul 2, 2025 5:37am

Copy link
Contributor

coderabbitai bot commented Jul 2, 2025

Walkthrough

The updates reorganize and clarify documentation and references for Universal Bridge and Buy Crypto features, introduce new UI widgets, add and update several API methods (including for ERC4337, ERC7702, Onramp, and server wallet management), and consolidate buy-related functions. A minor TypeScript code adjustment improves type safety when transforming documentation data.

Changes

File(s) Change Summary
apps/portal/public/llms.txt Reorganized and updated documentation: added Universal Bridge widgets, new API methods for ERC4337, ERC7702, Onramp, and Engine; consolidated Buy Crypto functions under Miscellaneous; clarified deprecations and new features.
apps/portal/src/app/references/components/TDoc/fetchDocs/fetchTypeScriptDoc.ts Introduced a TransformArg type alias and refactored the transform function call for improved type safety.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant UI (Widgets)
    participant UniversalBridge
    participant Onramp
    participant Engine

    User->>UI (Widgets): Interact (BuyWidget/CheckoutWidget/TransactionWidget)
    UI (Widgets)->>UniversalBridge: Initiate purchase/onramp
    UniversalBridge->>Onramp: prepare()
    Onramp-->>UniversalBridge: Return preparation result
    UniversalBridge->>Onramp: status()
    Onramp-->>UniversalBridge: Return transaction status
    UniversalBridge->>Engine: createServerWallet() / getServerWallets() / searchTransactions()
    Engine-->>UniversalBridge: Return wallet/transaction data
    UniversalBridge-->>UI (Widgets): Update UI with results
    UI (Widgets)-->>User: Display status/confirmation
Loading

Possibly related PRs

  • thirdweb-dev/js#7265: Revises and replaces Universal Bridge documentation and guides with new SDK usage examples and integration tutorials, directly relating to the documentation and reference updates in this PR.

Warning

Review ran into problems

🔥 Problems

Errors were encountered while retrieving linked issues.

Errors (1)
  • TEAM-0000: Entity not found: Issue - Could not find referenced Issue.
✨ Finishing Touches
  • 📝 Generate Docstrings

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

graphite-app bot commented Jul 2, 2025

How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • merge-queue - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

@github-actions github-actions bot added the Portal Involves changes to the Portal (docs) codebase. label Jul 2, 2025
@joaquim-verges joaquim-verges force-pushed the 07-02-fix_llm.txt_generation branch from 86f698c to b767189 Compare July 2, 2025 05:28
@vercel vercel bot temporarily deployed to Preview – wallet-ui July 2, 2025 05:28 Inactive
@vercel vercel bot temporarily deployed to Preview – nebula July 2, 2025 05:28 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb-www July 2, 2025 05:28 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground July 2, 2025 05:28 Inactive
Copy link
Member Author


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • merge-queue - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

Copy link

codecov bot commented Jul 2, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 51.92%. Comparing base (2d1549b) to head (b767189).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #7500   +/-   ##
=======================================
  Coverage   51.92%   51.92%           
=======================================
  Files         949      949           
  Lines       64148    64148           
  Branches     4229     4229           
=======================================
  Hits        33311    33311           
  Misses      30731    30731           
  Partials      106      106           
Flag Coverage Δ
packages 51.92% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@joaquim-verges joaquim-verges changed the title fix llm.txt generation [Porta] fix llm.txt generation Jul 2, 2025
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
apps/portal/public/llms.txt (2)

11-13: Grammatical consistency – add the missing “is” in widget descriptions

Two of the newly-added widget bullet points omit the verb, breaking the parallel structure used elsewhere.

-* [Widgets.CheckoutWidget](https://portal.thirdweb.com/references/typescript/v5/widgets/CheckoutWidget): Widget a prebuilt UI for purchasing a specific token.
-* [Widgets.TransactionWidget](https://portal.thirdweb.com/references/typescript/v5/widgets/TransactionWidget): Widget a prebuilt UI for purchasing a specific token.
+* [Widgets.CheckoutWidget](https://portal.thirdweb.com/references/typescript/v5/widgets/CheckoutWidget): **Widget is** a prebuilt UI for purchasing a specific token.
+* [Widgets.TransactionWidget](https://portal.thirdweb.com/references/typescript/v5/widgets/TransactionWidget): **Widget is** a prebuilt UI for purchasing a specific token.

109-111: Duplicate “# Utils” heading will collide with the global “# Utils” section

There is already a top-level “# Utils” section at line 1185.
Re-using the same markdown heading text creates duplicate anchor IDs in the generated docs, which breaks intra-page links.

Consider:

-# Utils
+# Hooks – Utils

or downgrade it to ## Utils so the anchor becomes unique (e.g. react-hooks-utils).

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2d1549b and b767189.

📒 Files selected for processing (2)
  • apps/portal/public/llms.txt (8 hunks)
  • apps/portal/src/app/references/components/TDoc/fetchDocs/fetchTypeScriptDoc.ts (2 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
`**/*.{ts,tsx}`: Write idiomatic TypeScript with explicit function declarations ...

**/*.{ts,tsx}: Write idiomatic TypeScript with explicit function declarations and return types
Limit each file to one stateless, single-responsibility function for clarity
Re-use shared types from @/types or local types.ts barrels
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Choose composition over inheritance; leverage utility types (Partial, Pick, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose
Load heavy dependencies inside async paths to keep initial bundle lean (lazy loading)

📄 Source: CodeRabbit Inference Engine (CLAUDE.md)

List of files the instruction was applied to:

  • apps/portal/src/app/references/components/TDoc/fetchDocs/fetchTypeScriptDoc.ts
🧠 Learnings (3)
📓 Common learnings
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Surface breaking changes prominently in PR descriptions
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/wallets/**/*.{ts,tsx} : Support EIP-1193, EIP-5792, EIP-7702 standards in wallet architecture
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/wallets/**/*.{ts,tsx} : Unified `Wallet` and `Account` interfaces in wallet architecture
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/wallets/**/*.{ts,tsx} : Support for in-app wallets (social/email login) in wallet architecture
apps/portal/src/app/references/components/TDoc/fetchDocs/fetchTypeScriptDoc.ts (12)
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to **/*.{ts,tsx} : Write idiomatic TypeScript with explicit function declarations and return types
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to apps/{dashboard,playground-web}/**/*.{tsx,ts} : Server Side Data Fetching: Return typed results (`Project[]`, `User[]`) – avoid `any`
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to **/*.{ts,tsx} : Comment only ambiguous logic; avoid restating TypeScript in prose
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to **/*.{ts,tsx} : Avoid `any` and `unknown` unless unavoidable; narrow generics when possible
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to **/*.{ts,tsx} : Prefer type aliases over interface except for nominal shapes
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard/**/api/**/*.{ts,tsx} : Return typed results (`Project[]`, `User[]`, …) – avoid `any`.
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to **/*.{ts,tsx} : Re-use shared types from `@/types` or local `types.ts` barrels
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to packages/thirdweb/src/exports/**/*.{ts,tsx} : Every public symbol must have comprehensive TSDoc with at least one `@example` block that compiles and custom annotation tags (`@beta`, `@internal`, `@experimental`)
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/extensions/**/*.{ts,tsx} : Auto-generated contracts from ABI definitions in extensions
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to **/*.{ts,tsx} : Choose composition over inheritance; leverage utility types (`Partial`, `Pick`, etc.)
Learnt from: MananTank
PR: thirdweb-dev/js#7152
File: apps/dashboard/src/app/(app)/(dashboard)/(chain)/[chain_id]/[contractAddress]/accounts/page.tsx:2-10
Timestamp: 2025-05-26T16:28:10.079Z
Learning: In Next.js 14+, the `params` object in page components is always a Promise that needs to be awaited, so the correct typing is `params: Promise<ParamsType>` rather than `params: ParamsType`.
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to packages/thirdweb/src/exports/**/*.{ts,tsx} : Export everything via `exports/` directory, grouped by feature in the public API of the SDK
apps/portal/public/llms.txt (28)

undefined

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Surface breaking changes prominently in PR descriptions
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/wallets/**/*.{ts,tsx} : Unified Wallet and Account interfaces in wallet architecture
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard/**/components/*.client.tsx : Interactive UI that relies on hooks (useState, useEffect, React Query, wallet hooks).
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/wallets/**/*.{ts,tsx} : Support for in-app wallets (social/email login) in wallet architecture
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/wallets/**/*.{ts,tsx} : Smart wallets with account abstraction in wallet architecture
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to apps/{dashboard,playground-web}/**/*.{tsx,ts} : Import UI primitives from @/components/ui/* (Button, Input, Select, Tabs, Card, Sidebar, Badge, Separator) in dashboard and playground apps
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard//components//*.{ts,tsx} : Reuse core UI primitives; avoid re-implementing buttons, cards, modals.
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to apps/{dashboard,playground-web}/**/*.{tsx,ts} : Client Components: Handle interactive UI with React hooks (useState, useEffect, React Query, wallet hooks)
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard//components//*.{ts,tsx} : Always import from the central UI library under @/components/ui/* – e.g. import { Button } from "@/components/ui/button".
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to apps/{dashboard,playground-web}/**/*.{tsx,ts} : Client Components: Access browser APIs (localStorage, window, IntersectionObserver)
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard/**/components/*.client.tsx : When you need access to browser APIs (localStorage, window, IntersectionObserver etc.).
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard/**/components/*.client.tsx : Anything that consumes hooks from @tanstack/react-query or thirdweb SDKs.
</retrieved_learning>

<retrieved_learning>
Learnt from: MananTank
PR: #7356
File: apps/nebula/src/app/not-found.tsx:1-1
Timestamp: 2025-06-17T18:30:52.976Z
Learning: In the thirdweb/js project, the React namespace is available for type annotations (like React.FC) without needing to explicitly import React. This is project-specific configuration that differs from typical TypeScript/React setups.
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/exports/react.native.ts : React Native specific exports are in src/exports/react.native.ts
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to apps/{dashboard,playground-web}/**/*.{tsx,ts} : Use design system tokens (e.g., bg-card, border-border, text-muted-foreground)
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard//components//*.{ts,tsx} : For notices & skeletons rely on AnnouncementBanner, GenericLoadingPage, EmptyStateCard.
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/extensions/**/*.{ts,tsx} : Composable functions with TypeScript safety in extensions
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/extensions/**/*.{ts,tsx} : Auto-generated contracts from ABI definitions in extensions
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/extensions/**/*.{ts,tsx} : Support for read/write operations in extensions
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.489Z
Learning: Applies to src/wallets/**/*.{ts,tsx} : Support EIP-1193, EIP-5792, EIP-7702 standards in wallet architecture
</retrieved_learning>

<retrieved_learning>
Learnt from: joaquim-verges
PR: #7268
File: packages/thirdweb/src/wallets/in-app/core/wallet/in-app-core.ts:210-216
Timestamp: 2025-06-03T23:44:40.243Z
Learning: EIP7702 wallets do not need special handling for switching chains, unlike EIP4337 wallets which require reconnection when switching chains. In the switchChain method condition, EIP7702 should be intentionally excluded from the reconnection logic.
</retrieved_learning>

<retrieved_learning>
Learnt from: MananTank
PR: #7081
File: apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/assets/create/create-token-page-impl.tsx:110-118
Timestamp: 2025-05-20T18:54:15.781Z
Learning: In the thirdweb dashboard's token asset creation flow, the transferBatch function from thirdweb/extensions/erc20 accepts the raw quantity values from the form without requiring explicit conversion to wei using toUnits(). The function appears to handle this conversion internally or is designed to work with the values in the format they're already provided.
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to test/src/test-wallets.ts : Predefined test accounts are in test/src/test-wallets.ts
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-06-30T10:25:29.488Z
Learning: Applies to packages/thirdweb/src/exports/**/*.{ts,tsx} : Export everything via exports/ directory, grouped by feature in the public API of the SDK
</retrieved_learning>

<retrieved_learning>
Learnt from: gregfromstl
PR: #7450
File: packages/thirdweb/src/bridge/Webhook.ts:57-81
Timestamp: 2025-06-26T19:46:04.024Z
Learning: In the onramp webhook schema (packages/thirdweb/src/bridge/Webhook.ts), the currencyAmount field is intentionally typed as z.number() while other amount fields use z.string() because currencyAmount represents fiat currency amounts in decimals (like $10.50), whereas other amount fields represent token amounts in wei (very large integers that benefit from bigint representation). The different naming convention (currencyAmount vs amount) reflects this intentional distinction.
</retrieved_learning>

<retrieved_learning>
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-06-30T10:26:04.389Z
Learning: Applies to dashboard//components//*.{ts,tsx} : Stick to design-tokens: background (bg-card), borders (border-border), muted text (text-muted-foreground) etc.
</retrieved_learning>

<retrieved_learning>
Learnt from: MananTank
PR: #7177
File: apps/dashboard/src/app/(app)/(dashboard)/(chain)/[chain_id]/[contractAddress]/public-pages/erc20/_hooks/useTokenPriceData.ts:49-49
Timestamp: 2025-05-27T19:55:25.056Z
Learning: In the ERC20 public pages token price data hook (useTokenPriceData.ts), direct array access on json.data[0] without optional chaining is intentionally correct and should not be changed to use safety checks.
</retrieved_learning>

<retrieved_learning>
Learnt from: MananTank
PR: #7298
File: apps/dashboard/src/app/nebula-app/move-funds/move-funds.tsx:255-277
Timestamp: 2025-06-06T23:47:55.122Z
Learning: The transfer function from thirdweb/extensions/erc20 accepts human-readable amounts via the amount property and automatically handles conversion to base units (wei) by fetching the token decimals internally. Manual conversion using toWei() is not required when using the amount property.
</retrieved_learning>

⏰ Context from checks skipped due to timeout of 90000ms (2)
  • GitHub Check: Size
  • GitHub Check: Analyze (javascript)
🔇 Additional comments (3)
apps/portal/src/app/references/components/TDoc/fetchDocs/fetchTypeScriptDoc.ts (2)

4-4: Excellent type safety improvement!

The TransformArg type alias elegantly extracts the exact parameter type expected by the transform function using Parameters<typeof transform>[0]. This follows TypeScript best practices and coding guidelines by providing explicit typing.


16-16: LGTM! Type casting improves safety.

Explicitly casting doc.default as TransformArg is much better than using @ts-expect-error (which was likely here before). This approach:

  • Makes the type transformation explicit and intentional
  • Ensures type safety by using the exact type expected by transform
  • Follows coding guidelines about avoiding any and maintaining proper TypeScript practices
apps/portal/public/llms.txt (1)

1261-1263: Out-of-date cross-reference: Bridge.status no longer present

The note for getBuyWithCryptoStatus directs users to Bridge.status, but there is no such API in the current docs. It should probably point at Onramp.status (or another renamed helper).

Please update the sentence accordingly to avoid dead links.

Comment on lines +991 to +994
## Onramp
* [Onramp.prepare](https://portal.thirdweb.com/references/typescript/v5/onramp/prepare): Prepares an onramp transaction, returning a link from the specified provider to onramp to the specified token.
* [Onramp.status](https://portal.thirdweb.com/references/typescript/v5/onramp/status): Retrieves the status of an Onramp session created via Bridge.Onramp.prepare. The status will include any on-chain transactions that have occurred as a result of the onramp as well as any arbitrary `purchaseData` that was supplied when the onramp was prepared.
---
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Namespace confusion – reference should be Onramp.prepare/status

The description still says “Bridge.Onramp.prepare” which no longer exists after the recent refactor to a first-level Onramp API.

-Retrieves the status of an Onramp session created via Bridge.Onramp.prepare.
+Retrieves the status of an Onramp session created via Onramp.prepare.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
## Onramp
* [Onramp.prepare](https://portal.thirdweb.com/references/typescript/v5/onramp/prepare): Prepares an onramp transaction, returning a link from the specified provider to onramp to the specified token.
* [Onramp.status](https://portal.thirdweb.com/references/typescript/v5/onramp/status): Retrieves the status of an Onramp session created via Bridge.Onramp.prepare. The status will include any on-chain transactions that have occurred as a result of the onramp as well as any arbitrary `purchaseData` that was supplied when the onramp was prepared.
---
## Onramp
* [Onramp.prepare](https://portal.thirdweb.com/references/typescript/v5/onramp/prepare): Prepares an onramp transaction, returning a link from the specified provider to onramp to the specified token.
* [Onramp.status](https://portal.thirdweb.com/references/typescript/v5/onramp/status): Retrieves the status of an Onramp session created via Onramp.prepare. The status will include any on-chain transactions that have occurred as a result of the onramp as well as any arbitrary `purchaseData` that was supplied when the onramp was prepared.
---
🤖 Prompt for AI Agents
In apps/portal/public/llms.txt around lines 991 to 994, update the references
and descriptions to remove "Bridge." prefix from "Bridge.Onramp.prepare" and
"Bridge.Onramp.status" since the API was refactored to a first-level Onramp
namespace. Change all mentions to just "Onramp.prepare" and "Onramp.status" to
reflect the current API structure accurately.

Copy link
Contributor

github-actions bot commented Jul 2, 2025

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 63.11 KB (0%) 1.3 s (0%) 322 ms (+167.74% 🔺) 1.6 s
thirdweb (cjs) 352.76 KB (0%) 7.1 s (0%) 1.1 s (+9.26% 🔺) 8.1 s
thirdweb (minimal + tree-shaking) 5.72 KB (0%) 115 ms (0%) 133 ms (+1987.9% 🔺) 248 ms
thirdweb/chains (tree-shaking) 530 B (0%) 11 ms (0%) 60 ms (+1749.23% 🔺) 70 ms
thirdweb/react (minimal + tree-shaking) 19.59 KB (0%) 392 ms (0%) 134 ms (+645.22% 🔺) 525 ms

@joaquim-verges joaquim-verges merged commit f15f62f into main Jul 2, 2025
24 of 25 checks passed
@joaquim-verges joaquim-verges deleted the 07-02-fix_llm.txt_generation branch July 2, 2025 05:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Portal Involves changes to the Portal (docs) codebase.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant