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

chore(js-ts): Convert app/util/validators/index.js to TypeScript #11299

Merged
merged 5 commits into from
Sep 23, 2024

Conversation

devin-ai-integration[bot]
Copy link
Contributor

@devin-ai-integration devin-ai-integration bot commented Sep 18, 2024

chore(js-ts): Convert app/util/validators/index.js to TypeScript

Description

This PR converts the app/util/validators/index.js file to TypeScript. The conversion process involved adding type annotations to functions and variables while maintaining the original functionality.

Changes

  • Renamed file from index.js to index.ts
  • Added type annotations to function parameters and return types
  • Imported Wordlist from '@ethersproject/wordlists' (although not used in the current implementation)
  • Added type annotation for vaultSeed variable in parseVaultValue function
  • Added type assertion for result in parseVaultValue function to address 'unknown' type issue

Notable Decisions

  • Kept the original export of isValidMnemonic from ethers.utils as requested:
    export const { isValidMnemonic } = ethers.utils;

Testing

  • Ensured all existing functionality remains intact
  • Verified that TypeScript compiler doesn't throw any errors

Next Steps

  • Review and test the changes thoroughly
  • Update any related documentation if necessary

Branch

This PR is created from the branch: devin/convert-ts-app-util-validators-index-0918

Additional Information

If you have any feedback, you can leave comments in the PR and I'll address them in the app!

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.

Copy link
Contributor

@Cal-L Cal-L left a comment

Choose a reason for hiding this comment

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

LGTM

@Cal-L Cal-L marked this pull request as ready for review September 23, 2024 20:12
@Cal-L Cal-L requested a review from a team as a code owner September 23, 2024 20:12
@Cal-L Cal-L added team-mobile-platform team-ai AI team (for the Devin AI bot) labels Sep 23, 2024
Copy link

@Cal-L Cal-L added this pull request to the merge queue Sep 23, 2024
Merged via the queue into main with commit ff926db Sep 23, 2024
39 of 42 checks passed
@Cal-L Cal-L deleted the devin/convert-ts-app-util-validators-index-0918 branch September 23, 2024 23:49
@github-actions github-actions bot locked and limited conversation to collaborators Sep 23, 2024
@metamaskbot metamaskbot added the release-7.33.0 Issue or pull request that will be included in release 7.33.0 label Sep 23, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-7.33.0 Issue or pull request that will be included in release 7.33.0 team-ai AI team (for the Devin AI bot) team-mobile-platform
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants