useIsMountedRef set its ref in a passive effect, which React runs some time after the commit. In between, the component is in the DOM and can be clicked while the ref still says it is not mounted, and useToggle drops the click. The Accounts page showed it: an "Account" click right after the page drew did not open the create modal. Under load in a spec this happened in one run out of five. A layout effect runs during the commit, before an event can reach the component; unmounting still clears the ref.
@pezkuwi/apps
A Portal into the Pezkuwi and Bizinikiwi networks. Provides a view and interaction layer from a browser.
It is hosted at https://apps.pezkuwichain.io to explore any of the supported Pezkuwi and Bizinikiwi chains.
Important If you are a chain developer and would like to add support for your chain to the UI, all the local configuration (API types, settings, logos) can be customized in the apps-config package, complete with instructions of what goes where.
Overview
The repo is split into a number of packages, each representing an application.
Development
Contributions are welcome!
To start off, this repo (along with others in the @pezkuwi family) uses yarn workspaces to organize the code. As such, after cloning dependencies should be installed via yarn, not via npm, the latter will result in broken dependencies.
To get started -
- Clone the repo locally, via
git clone https://github.com/pezkuwichain/pezkuwi-apps <optional local path> - Ensure that you have a recent LTS version of Node.js, for development purposes Node >= 16 is recommended.
- Ensure that you have a recent version of Yarn, for development purposes Yarn >= 1.22 is required.
- Install the dependencies by running
yarn install --frozen-lockfile - Ready! Now you can launch the UI (assuming you have a local Pezkuwi Node running), via
yarn run start - Access the UI via http://localhost:3000
Docker
To build and run a container with local changes -
docker build -t pezkuwi-apps -f docker/Dockerfile .
docker run --rm -it --name pezkuwi-ui -e WS_URL=ws://someip:9944 -p 80:80 pezkuwi-apps
The UI is then at http://localhost:80 (or just http://localhost)