To run the extension, run the following from the top level of the monorepo:
yarn
yarn extension start
You need to get the environment variables from 1password in order to get full functionality. Run the command yarn extension env:local:download
to copy them to your root folder.
- Go to chrome://extensions
- At the top right, turn on Developer mode
- Click Load unpacked
- Find and select the extension folder (apps/extension/dev)
Our scantastic API requires a consistent origin header so the build must be loaded from an absolute path. This works because Chrome generates a consistent ID for the extension based on the path it was loaded from.
To run the extension, run the following from the top level of the monorepo:
Mac:
yarn
yarn extension start:absolute
Windows:
yarn
yarn extension start:absolute:windows
- Go to chrome://extensions
- At the top right, turn on Developer mode
- Click Load unpacked
- Find and select the extension folder with an absolute path (
/Users/Shared/stretch
on Mac andC:/ProgramData/stretch
on Windows) - Your chrome extension url should be
chrome-extension://ceofpnbcmdjbibjjdniemjemmgaibeih
on Mac andchrome-extension://ffogefanhjekjafbpofianlhkonejcoe
on Windows. The backend allows this origin and the ID will be consistently generated based off an absolute path that is consistent on all machines.
We use redux-persist
to persist the Redux state between user sessions. Most of this state is shared between the mobile app and the extension. Please review the Wallet Migrations README for details on how to write migrations when you add or remove anything from the Redux state structure.