HomePhabricator

[Cashtab] Route to onboarding if no wallet present

Description

[Cashtab] Route to onboarding if no wallet present

Summary: Related to T2090. Users should not be able to navigate to a component other than OnBoarding.js before creating a wallet. Logic has been added to routes which could previously be accessed before importing/creating a wallet, making it so the user can only see the OnBoarding component.

Test Plan:
cd web/cashtab && npm start
navigate to localhost:3000 in a private browser
enter the following Routes:
/tokens
/airdrop
/configure
/send

Observe that if there is no wallet present, these routes will bring the user to the OnBoarding component.

Reviewers: bytesofman, #bitcoin_abc

Reviewed By: bytesofman, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D11572