Skip to content
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

feat: add new default networks #28006

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

salimtb
Copy link
Contributor

@salimtb salimtb commented Oct 22, 2024

Description

This PR ensures that a predefined list of popular networks (Arbitrum, BSC, Base, Optimism, and Polygon) is automatically added for new users only during the app startup process. The networks are added using NetworkController.addNetwork within the useEffect hook inside the app's initialization flow.

Open in GitHub Codespaces

Related issues

Fixes:

Manual testing steps

  1. Install new metamask extension
  2. Import/create your wallet
  3. check the list of added networks

Screenshots/Recordings

Before

After

Screenshot 2024-10-22 at 15 42 32

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Copy link
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@salimtb salimtb force-pushed the salim/add-new-default-networks branch from eb72be5 to 9354d02 Compare October 22, 2024 13:45
@salimtb salimtb added the needs-assets-ux-review A shared label between the Assets and UX team to flag PRs ready for consolidated team review. label Oct 23, 2024
@salimtb salimtb marked this pull request as ready for review October 23, 2024 09:54
@salimtb salimtb requested review from a team as code owners October 23, 2024 09:54
@metamaskbot
Copy link
Collaborator

Builds ready [7225d92]
Page Load Metrics (1891 ± 74 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint16792403189115373
domContentLoaded16692354185414268
load16792402189115474
domInteractive21110482010
backgroundConnect9123403215
firstReactRender49212943517
getState4341084
initialActions01000
loadScripts11911903137714067
setupStore1181352412
uiStartup18712584211118589
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 0 Bytes (0.00%)
  • ui: 1.23 KiB (0.02%)
  • common: 84 Bytes (0.00%)

gambinish
gambinish previously approved these changes Oct 23, 2024
Copy link
Contributor

@gambinish gambinish left a comment

Choose a reason for hiding this comment

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

Pulled and tested, LGTM. Just left a curious comment, but doesn't need to be implemented ✅

ui/pages/onboarding-flow/welcome/welcome.js Outdated Show resolved Hide resolved
Copy link
Member

@andreahaku andreahaku left a comment

Choose a reason for hiding this comment

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

small comment on better handling of batch promises

ui/pages/onboarding-flow/welcome/welcome.js Outdated Show resolved Hide resolved
Copy link
Member

@andreahaku andreahaku left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-assets-ux-review A shared label between the Assets and UX team to flag PRs ready for consolidated team review. team-assets
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants