Skip to content

docs: Update documentation for controller PR #2106#115

Merged
kronosapiens merged 1 commit intomainfrom
docs-update-1760032229
Oct 10, 2025
Merged

docs: Update documentation for controller PR #2106#115
kronosapiens merged 1 commit intomainfrom
docs-update-1760032229

Conversation

@tarrencev
Copy link
Contributor

@tarrencev tarrencev commented Oct 9, 2025

This PR updates the documentation to reflect changes made in cartridge-gg/controller#2106

**Original PR Details:**
- Title: Change default chain from Sepolia to mainnet in keychain
- Files changed: examples/next/src/components/providers/StarknetProvider.tsx

packages/keychain/src/components/connect/create/username/account-search-dropdown.tsx
packages/keychain/src/components/connect/create/username/index.tsx
packages/keychain/src/hooks/connection.ts
packages/keychain/src/hooks/device.ts

Please review the documentation changes to ensure they accurately reflect the controller updates.

Note

Updates docs to use mainnet as the default chain and RPC across Node, React, and Getting Started examples (formerly Sepolia).

  • Documentation updates (controller):
    • Defaults moved to mainnet:
      • src/pages/controller/examples/node.md: rpc.../mainnet, chainIdSN_MAIN.
      • src/pages/controller/examples/react.md: JSON-RPC provider now defaults to .../mainnet for unspecified chains.
      • src/pages/controller/getting-started.mdx:
        • Controller config defaultChainIdSN_MAIN.
        • StarknetProvider defaultChainIdmainnet.id and provider defaults mainnet for unspecified chains.
        • SessionConnector example: rpc.../mainnet, chainIdSN_MAIN.

Written by Cursor Bugbot for commit adf42cd. This will update automatically on new commits. Configure here.

    Updates documentation to reflect changes made in:
    Change default chain from Sepolia to mainnet in keychain

    Related controller PR: cartridge-gg/controller#2106
@vercel
Copy link

vercel bot commented Oct 9, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Updated (UTC)
docs Ready Ready Preview Oct 9, 2025 5:51pm

@claude
Copy link
Contributor

claude bot commented Oct 9, 2025

Claude finished @tarrencev's task —— View job


Code Review Completed ✅

I've thoroughly reviewed the documentation updates for controller PR #2106. Here's my comprehensive analysis:

Review Tasks

  • Read and analyze modified documentation files
  • Check accuracy of chain configuration updates
  • Review consistency across all affected files
  • Assess completeness of documentation changes
  • Provide feedback on code quality and best practices
  • Check for potential issues or missing updates

Summary

This PR correctly updates the documentation to reflect the controller change from Sepolia to mainnet as the default chain. The changes are accurate, consistent, and well-implemented.

Detailed Review Findings

Code Quality & Best Practices

  • Clean, focused changes: Updates are surgical and only modify the necessary configuration values
  • Consistent patterns: All files follow the same pattern of making mainnet the default while keeping Sepolia as fallback
  • Good documentation structure: Code examples remain clear and well-commented

Accuracy of Changes

All chain configuration updates are correct:

  • Default chain IDs: SN_SEPOLIASN_MAIN
  • Default RPC endpoints: Sepolia → mainnet URLs ✅
  • Provider logic: Mainnet case now comes first with proper default fallback ✅
  • React chain IDs: sepolia.idmainnet.id

Consistency Across Files

Changes maintain consistency across all three documentation files:

  • Node.js example (src/pages/controller/examples/node.md:52-53): Updated SessionProvider config
  • React example (src/pages/controller/examples/react.md:93-96, 106): Updated provider logic and StarknetConfig
  • Getting Started (src/pages/controller/getting-started.mdx:91, 127-130, 139, 196-197): Updated Controller and SessionConnector configs

Completeness Assessment

The documentation changes properly cover:

  • All example configurations now use mainnet as default
  • Sepolia remains available as an alternative chain option
  • Both SessionProvider and ControllerConnector patterns updated
  • No breaking changes to existing API usage patterns

Security & Performance

  • No security concerns: Changes only affect default configuration values
  • No performance impact: Network endpoint changes don't affect performance
  • Maintains backward compatibility: Sepolia still available for developers who need testnet

Best Practices Maintained

  • Proper TypeScript typing preserved
  • Error handling patterns unchanged
  • Configuration flexibility maintained (developers can still override defaults)
  • Clear separation between mainnet and testnet usage

Recommendations

Minor Enhancement Opportunity: Consider adding a brief note in the documentation explaining when developers might want to use Sepolia vs mainnet (e.g., "Use Sepolia for testing and development, mainnet for production applications").

Conclusion

LGTM 🚢 - This PR successfully updates the documentation to reflect the controller's new mainnet-first approach while maintaining all existing functionality and patterns. The changes are minimal, focused, and maintain excellent documentation quality.


@kronosapiens kronosapiens merged commit 8ff6346 into main Oct 10, 2025
3 checks passed
@kronosapiens kronosapiens deleted the docs-update-1760032229 branch October 10, 2025 16:29
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.

2 participants