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

Create a refactor proposal for logic and structure of hwWallet in electron and react #1954

Closed
osvaldovega opened this issue Apr 24, 2019 · 0 comments · Fixed by #2464
Closed
Assignees

Comments

@osvaldovega
Copy link
Contributor

Description of the problem

At this moment the hwWallet code is split in hwWallet middleware functions in utils and utils/api, in these 3 places the hwWallets are being check and based on an action this trigger an specific event, some information is being set in the localStorage and in the same time in the redux store.

So the problem at this moment is that some data could be duplicated in the project and store in localStorage and this could be not necessary.

Suggested solution

Create a generic/modular solution that helps to handle any hwWallet device detection and interaction for dont have to change or add files in the future to handle a new hardware wallet device, so the communication and interaction could be the same in the react project and then in the electron part implement the logic for the specific device.

So for the react part we can update or modify the actions, reducers, local storage and then middlewares and find the better place to handle the ipc messages and the dispatch of the actions, then check if the actual structure that we have for this can be redefine and then remove it from the local storage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants