Closed qasimfida closed 2 years ago
Possible duplicate of #297.
I've tried installing these packages with both npm and yarn. Still go no luck with this bug. @NoahZinsmeister I also need a connector of TRUST WALLET.
I'm stuck on this bug for 2 weeks. Please help me.
@qasimfida Trust Wallet uses WalletConnect as a provider, so no need for a specific connector. General flow is select WalletConnect provider, and when the QR code pops up you scan from your Trust Wallet app on your mobile device. In the app go to Settings --> WalletConnect to open the QR code scanner.
Thanks you for the support. But the above mention loader error is still with the wallet connect.
I've tried the your answers but not found useful. If you can help me this I would be very thankful to you.
It sounds like it might be a Babel issue. Take a look at this SO for help https://stackoverflow.com/a/33470546/2117600
ERROR in ./node_modules/eth-json-rpc-filters/node_modules/pify/index.js Module parse failed: Unexpected token (44:2) You may need an appropriate loader to handle this file type. | errorFirst: true, | promiseModule: Promise, | ...options | };
While using these wallets. import { WalletConnectConnector } from '@web3-react/walletconnect-connector'; import { WalletLinkConnector } from '@web3-react/walletlink-connector'; import { AuthereumConnector } from '@web3-react/authereum-connector'; import { LatticeConnector } from '@web3-react/lattice-connector'; import { TorusConnector } from '@web3-react/torus-connector';
getting this error. You may need an appropriate loader to handle this file type. | errorFirst: true, | promiseModule: Promise, | ...options | };
const POLLING_INTERVAL = 12000; const PORTIS_DAPP_ID = 'c0e2bf01-4b08-4fd5-ac7b-8e26b58cd236'; const RPC_URLS: { [chainId: number]: string } = { 1: 'https://mainnet.infura.io/v3/84842078b09946638c03157f83405213', 4: 'https://rinkeby.infura.io/v3/84842078b09946638c03157f83405213', };
here are the constructors. export const walletlink = new WalletLinkConnector({ url: RPC_URLS[1], appName: 'web3-react example', supportedChainIds: [1, 3, 4, 5, 42, 10, 137, 69, 420, 80001], }); export const authereum = new AuthereumConnector({ chainId: 42 }); export const lattice = new LatticeConnector({ chainId: 4, appName: 'web3-react', url: RPC_URLS[4], }); export const torus = new TorusConnector({ chainId: 1 });
Package json
{ "name": "my-app", "version": "0.1.0", "private": true, "dependencies": { "@ant-design/icons": "^2.1.1", "@ethersproject/keccak256": "^5.4.0", "@ethersproject/providers": "^5.4.5", "@ethersproject/units": "^5.4.0", "@metamask/detect-provider": "^1.2.0", "@web3-react/abstract-connector": "^6.0.7", "@web3-react/authereum-connector": "^6.2.0", "@web3-react/core": "^6.1.9", "@web3-react/fortmatic-connector": "^6.1.6", "@web3-react/frame-connector": "^6.0.9", "@web3-react/injected-connector": "^6.0.7", "@web3-react/lattice-connector": "^6.1.9", "@web3-react/ledger-connector": "^6.1.9", "@web3-react/network-connector": "^6.1.9", "@web3-react/portis-connector": "^6.1.9", "@web3-react/squarelink-connector": "^6.1.9", "@web3-react/torus-connector": "^6.1.9", "@web3-react/trezor-connector": "^6.1.9", "@web3-react/walletconnect-connector": "^6.2.4", "@web3-react/walletlink-connector": "^6.2.5", "antd": "^3.4.1", "async-redis": "^2.0.0", "bootstrap": "^5.1.0", "bscscan-api": "^1.0.1", "chessboardjs": "^0.0.1", "dotenv": "^4.0.0", "ethers": "^5.4.6", "express": "^4.16.3", "husky": "^7.0.2", "immutable": "^3.8.2", "lint-staged": "^11.1.2", "node-cron": "^3.0.0", "node-schedule": "^1.3.0", "nodemon": "^2.0.13", "normalize.css": "^8.0.0", "prettier": "^2.3.2", "react": "^16.3.1", "react-copy-to-clipboard": "^5.0.4", "react-countdown-circle-timer": "^2.5.4", "react-dom": "^16.3.1", "react-router": "^5.2.1", "react-router-dom": "^5.3.0", "react-scripts-ts": "^2.15.1", "react-spring": "^9.2.5", "react-toastify": "^8.0.3", "redis": "^2.8.0", "shortid": "^2.2.8", "socket.io": "^2.1.0", "socket.io-client": "^2.1.0", "toasted-notes": "^3.2.0", "web3": "^1.6.0" }, "scripts": { "start": "react-scripts-ts start", "server": "server/index.js", "nodemon": "nodemon server/index.js", "build": "react-scripts-ts build", "test": "react-scripts-ts test --env=jsdom", "eject": "react-scripts-ts eject", "create:component": "./node_modules/hygen/lib/bin.js component create", "create:store:item": "./node_modules/hygen/lib/bin.js store create", "heroku-postbuild": "yarn run build" }, "jest": { "moduleNameMapper": { "^react-native$": "react-native-web", "@App/(.*)": "/src/$1"
}
},
"devDependencies": {
"@types/history": "^4.6.2",
"@types/jest": "^22.2.2",
"@types/node": "^9.6.2",
"@types/react-dom": "^16.0.4",
"typescript": "^2.9.2"
}
}
Provider
export default function ({ uaddress }) { return (
); }