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: convert MetaMetricsController to typescript #28072

Merged
merged 11 commits into from
Oct 28, 2024

Conversation

cryptodev-2s
Copy link
Contributor

@cryptodev-2s cryptodev-2s commented Oct 24, 2024

Description

This PR converts MetaMetricsContrller to typescript

Open in GitHub Codespaces

Related issues

Fixes: #25924

Manual testing steps

Screenshots/Recordings

Before

After

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.

@cryptodev-2s cryptodev-2s requested a review from a team as a code owner October 24, 2024 13:45
@cryptodev-2s cryptodev-2s marked this pull request as draft October 24, 2024 13:45
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.

@cryptodev-2s cryptodev-2s self-assigned this Oct 24, 2024
@cryptodev-2s cryptodev-2s force-pushed the feature/convert-metametrics-to-typescript branch from 155a820 to 0819d7c Compare October 24, 2024 15:09
@cryptodev-2s cryptodev-2s marked this pull request as ready for review October 24, 2024 15:09
@cryptodev-2s cryptodev-2s changed the title feat: convert MetaMetrics controller to typescript feat: convert MetaMetricsController to typescript Oct 24, 2024
@cryptodev-2s cryptodev-2s force-pushed the feature/convert-metametrics-to-typescript branch from 0819d7c to fd6868f Compare October 24, 2024 15:11
@metamaskbot
Copy link
Collaborator

Builds ready [fd6868f]
Page Load Metrics (2002 ± 130 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint37726291924444213
domContentLoaded168125511964234113
load169626342002271130
domInteractive24135522814
backgroundConnect9293416129
firstReactRender482061073015
getState561252110
initialActions01000
loadScripts11902058143719996
setupStore1283332412
uiStartup188229872244301145
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 1.09 KiB (0.02%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Copy link
Contributor

@mcmire mcmire left a comment

Choose a reason for hiding this comment

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

Nice job! Most of my comments I believe were minor. In some cases it's more figuring out the correct behavior or really figuring out how best to communicate the existence of a possible bug.

app/scripts/controllers/metametrics.ts Outdated Show resolved Hide resolved
app/scripts/controllers/metametrics.ts Outdated Show resolved Hide resolved
app/scripts/controllers/metametrics.ts Outdated Show resolved Hide resolved
app/scripts/controllers/metametrics.ts Show resolved Hide resolved
app/scripts/controllers/metametrics.ts Outdated Show resolved Hide resolved
shared/constants/metametrics.ts Show resolved Hide resolved
shared/constants/metametrics.ts Show resolved Hide resolved
app/scripts/controllers/metametrics.test.ts Show resolved Hide resolved
app/scripts/controllers/metametrics.test.ts Outdated Show resolved Hide resolved
app/scripts/controllers/metametrics.test.ts Outdated Show resolved Hide resolved
@metamaskbot
Copy link
Collaborator

Builds ready [6e7f3a6]
Page Load Metrics (2011 ± 90 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint17802517200518086
domContentLoaded17712351196014972
load17802551201118790
domInteractive288847189
backgroundConnect10196454522
firstReactRender502901196330
getState596262814
initialActions00000
loadScripts12971778146513163
setupStore11100302713
uiStartup198329742278282135
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 1.26 KiB (0.03%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

@cryptodev-2s cryptodev-2s requested a review from mcmire October 25, 2024 17:28
@cryptodev-2s cryptodev-2s requested a review from kumavis as a code owner October 25, 2024 17:31
Copy link
Contributor

@mcmire mcmire left a comment

Choose a reason for hiding this comment

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

One more thing I noticed, but I will approve after that.

development/ts-migration-dashboard/files-to-convert.json Outdated Show resolved Hide resolved
Copy link
Contributor

@mcmire mcmire left a comment

Choose a reason for hiding this comment

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

LGTM!

@metamaskbot
Copy link
Collaborator

Builds ready [1913d74]
Page Load Metrics (2059 ± 102 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint181424372067212102
domContentLoaded17282371202520297
load178224412059212102
domInteractive239053209
backgroundConnect894412713
firstReactRender672041123115
getState684302612
initialActions01000
loadScripts12511805150017082
setupStore1278332411
uiStartup197727052316249120
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 626 Bytes (0.01%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Copy link
Member

@mikesposito mikesposito left a comment

Choose a reason for hiding this comment

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

Looks good!

@cryptodev-2s cryptodev-2s removed the request for review from kumavis October 28, 2024 10:13
@cryptodev-2s cryptodev-2s added this pull request to the merge queue Oct 28, 2024
Merged via the queue into develop with commit 317d2ef Oct 28, 2024
76 checks passed
@cryptodev-2s cryptodev-2s deleted the feature/convert-metametrics-to-typescript branch October 28, 2024 10:37
@github-actions github-actions bot locked and limited conversation to collaborators Oct 28, 2024
@metamaskbot metamaskbot added the release-12.7.0 Issue or pull request that will be included in release 12.7.0 label Oct 28, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-12.7.0 Issue or pull request that will be included in release 12.7.0 team-wallet-framework
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Convert MetaMetricsController (implementation + tests) to TypeScript
4 participants