Skip to content

fix: update#23

Merged
luu-alex merged 1 commit intoprodfrom
update-build-2
Apr 29, 2026
Merged

fix: update#23
luu-alex merged 1 commit intoprodfrom
update-build-2

Conversation

@luu-alex
Copy link
Copy Markdown

No description provided.

@luu-alex luu-alex merged commit 435ab5e into prod Apr 29, 2026
3 of 4 checks passed
@luu-alex luu-alex deleted the update-build-2 branch April 29, 2026 19:01
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces environment-aware default market selection, setting the default to 'VOLX-USDH' for testnet and 'CL-USDC' for other environments. The index route was updated to utilize these dynamic defaults. Feedback suggests that the useEffect hook in the index route may be redundant and potentially disruptive to the user experience, as it overrides persisted market selections every time the home page is visited.

Comment thread src/routes/index.tsx

useEffect(() => {
setSelectedMarket("all", "VOLX-USDH");
setSelectedMarket("all", DEFAULT_SELECTED_MARKETS.all);
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

This useEffect hook overrides the persisted market selection with the default value every time the user navigates to the home page. Since the marketStore already initializes with DEFAULT_SELECTED_MARKETS and handles persistence (as seen in use-market-store.ts), this call is likely redundant and potentially disruptive to the user experience as it clears their last selected market. Consider removing this useEffect block and the associated setSelectedMarket call to respect the persisted state.

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