-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
bugfix: homepage back #999
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💯
app/core/AppConstants.js
Outdated
@@ -23,5 +23,6 @@ export default { | |||
MM_UNIVERSAL_LINK_HOST: 'metamask.app.link', | |||
DAI_ADDRESS: '0x89d24a6b4ccb1b6faa2625fe562bdd9a23260359', | |||
HOMEPAGE_URL: 'https://home.metamask.io/', | |||
HOMEPAGE_HOST: 'home.metamask.io', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about to use getHost with HOMEPAGE_URL instead of declaring 2 almost identical constants?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you do that you can define a local const at the FILE level using
const HOMEPAGE_HOST = getHost(HOMEPAGE_URL)
;
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah the second option sounds good 👌
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good on both iOS and Android, QA Passed 👍
* goback from categories * HOMEPAGE_HOST
## **Description** <!-- Write a short description of the changes included in this pull request, also include relevant motivation and context. Have in mind the following questions: 1. What is the reason for the change? 2. What is the improvement/solution? --> ## **Related issues** Fixes: # ## **Manual testing steps** 1. Go to this page... 2. 3. ## **Screenshots/Recordings** <!-- If applicable, add screenshots and/or recordings to visualize the before and after of your change. --> ### **Before** <!-- [screenshots/recordings] --> ### **After** <!-- [screenshots/recordings] --> ## **Pre-merge author checklist** - [x] I’ve followed [MetaMask Coding Standards](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/CODING_GUIDELINES.md). - [x] I've clearly explained what problem this PR is solving and how it is solved. - [x] I've linked related issues - [x] I've included manual testing steps - [x] I've included screenshots/recordings if applicable - [x] I’ve included tests if applicable - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-mobile/blob/main/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. - [x] I’ve properly set the pull request status: - [ ] In case it's not yet "ready for review", I've set it to "draft". - [ ] In case it's "ready for review", I've changed it from "draft" to "non-draft". ## **Pre-merge reviewer checklist** - [x] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [x] 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. **Issue**: MetaMask/mobile-planning#999 **Description** The purpose of this PR is to migrate our store from old redux to [Redux Tool Kit](https://redux-toolkit.js.org/) - by focusing solely on updating the engine **Changes**: - installed @reduxjs/toolkit - updated store to use configureStore - created file persistConfig to export the persistedConfig object to the store file which will be more focused on configuring the store itself only - created a new space for future redux files in redux folder: for selectors and slices - migrated engine reducer into a state slice - added unit tests for engine slice **E2E Test**: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/b2781b20-539c-4f9e-b987-f9678ebc4ca5 **Possible future improvements:** - finish migrating reducers to RTK - ones that are mutating the state correctly can use createSlice or createReducer ! - replace thunk with createAsyncThunk or [React Query](https://redux-toolkit.js.org/rtk-query/overview) - move store file in reduxLayer - Upgrade Redux-Saga **NOTION Page for the findings**: https://www.notion.so/Redux-Toolkit-Performance-Upgrade-b10cb97d7ed44dfaa15b522951971037 **Current Reducers that need refactoring in the future for reference (out of scope):** - collectiblesReducer - privacyReducer - bookmarksReducer - browserReducer - modalsReducer - settingsReducer - alertReducer - transactionReducer - userReducer - wizardReducer - onboardingReducer - notificationReducer - swapsReducer - fiatOrders - infuraAvailabilityReducer - navigationReducer - networkOnboardReducer - securityReducer --------- Co-authored-by: João Loureiro <1649425+jpcloureiro@users.noreply.github.com> Co-authored-by: yande <110056475+Andepande@users.noreply.github.com> Co-authored-by: Yande <andepandy@outlook.com>
Description
Checklist
Issue
Resolves #982