2023-10-03 15:43:35 +00:00
|
|
|
# Wallet Connect Integration
|
|
|
|
|
|
|
|
## WalletConnect SDK management
|
|
|
|
|
2024-05-16 16:19:24 +00:00
|
|
|
To install/updates dependencies follow these steps by running the following commands in this directory:
|
2023-10-03 15:43:35 +00:00
|
|
|
|
2024-05-16 16:19:24 +00:00
|
|
|
- Step 1: update the [`package.json`](./package.json) versions and run `npm install`
|
2023-10-03 15:43:35 +00:00
|
|
|
- alternatively
|
|
|
|
- use the command `npm install <package-name>@<version/latest> --save` for individual packages
|
2023-11-24 12:51:36 +00:00
|
|
|
- or to update to the latest run `ncu -u; npm install` in here
|
|
|
|
- run `npm install -g npm-check-updates` for `ncu` command
|
2023-10-03 15:43:35 +00:00
|
|
|
- these commands will also create or update a `package-lock.json` file and populate the `node_modules` directory
|
2024-05-16 16:19:24 +00:00
|
|
|
- Step 2: update the [`bundle.js`](./generated/bundle.js) file by running `npm run build`
|
2023-10-03 15:43:35 +00:00
|
|
|
- the result will be embedded with the app and loaded by [`WalletConnectSDK.qml`](../WalletConnectSDK.qml) component
|
2024-05-16 16:19:24 +00:00
|
|
|
- Step 3: add the newly generated files to index `git add --update .` to include in the commit
|
2023-10-03 15:43:35 +00:00
|
|
|
|
|
|
|
## Testing
|
|
|
|
|
|
|
|
Use the web demo test client https://react-app.walletconnect.com/ for wallet pairing and https://react-auth-dapp.walletconnect.com/ for authentication
|
|
|
|
|
2023-11-18 16:06:04 +00:00
|
|
|
## Log
|
|
|
|
|
|
|
|
Initial setup
|
|
|
|
|
|
|
|
```sh
|
|
|
|
npm init -y
|
|
|
|
npm install --save-dev webpack webpack-cli webpack-dev-server
|
|
|
|
npm install --save @walletconnect/web3wallet
|
|
|
|
npm run build
|
|
|
|
# npm run build:dev # for development
|
|
|
|
```
|