Repository navigation
feat: dynamic asset data loading from GitHub - #201
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughRefactoring asset representation across the codebase: components and tools transition from assetId-based lookups to direct icon and symbol props. AssetService shifts from pre-instantiated singleton to lazy-initialized with remote data fetching. Backend tools enrich API responses with icon data. Related asset index moves from static to dynamically fetched at initialization. Changes
Sequence Diagram(s)sequenceDiagram
participant Server
participant AssetService
participant CoinGeckoAdapters
participant RelatedAssetIndex
participant App
Server->>Server: Application startup
Server->>AssetService: initialize()
par Parallel Initialization
AssetService->>AssetService: fetch asset data from remote
and
Server->>CoinGeckoAdapters: initializeCoinGeckoAdapters()
CoinGeckoAdapters->>CoinGeckoAdapters: fetch adapters per chain
and
Server->>RelatedAssetIndex: initializeRelatedAssetIndex()
RelatedAssetIndex->>RelatedAssetIndex: fetch related asset mappings
end
AssetService->>Server: initialize complete
Server->>AssetService: setOnStale(refreshCallback)
Server->>App: start listening & handle requests
Note over AssetService,Server: Background: on stale, AssetService<br/>triggers refresh callback
Estimated code review effort🎯 4 (Complex) | ⏱️ ~50 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Backend fetches asset data, CoinGecko adapters, and related asset index at startup instead of bundling ~5.4MB of static JSON. All tool responses are enriched with icon URLs so the frontend no longer needs assetService. Frontend AssetIcon is now prop-based, portfolio grouping uses relatedAssetKey from backend. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
31c8856 to
df1fe44
Compare
…edAssetKey, cleanup Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Summary
iconURLs so frontend no longer needsassetServiceAssetIconis now prop-based (icon?: string), portfolio grouping usesrelatedAssetKeyfrom backendTest plan
bun run buildpassesbun test— 558 pass, 0 failbun run dev— server initializes asset data from GitHub, starts servingrelatedAssetKey🤖 Generated with Claude Code
Summary by CodeRabbit
Release Notes
New Features
Improvements