Collectives™ on Stack Overflow
Find centralized, trusted content and collaborate around the technologies you use most.
Learn more about Collectives
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Learn more about Teams
I have imported InjectedConnector from @web3-react/injected-connector in my reactJS application for connecting it to meta mask wallet but on starting the vite server I is getting this error
✘ [ERROR] No matching export in "browser-external:events" for import "EventEmitter"
../../node_modules/@web3-react/abstract-connector/dist/abstract-connector.esm.js:1:9:
1 │ import { EventEmitter } from 'events';
Any idea what is going wrong here??
This is the complete error message displayed
error when starting dev server:
Error: Build failed with 1 error:
../../node_modules/@web3-react/abstract-connector/dist/abstract-connector.esm.js:1:9: ERROR: No matching export in "browser-external:events" for import "EventEmitter"
at failureErrorWithLog (/media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:1602:15)
at /media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:1248:28
at runOnEndCallbacks (/media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:1033:63)
at buildResponseToResult (/media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:1246:7)
at /media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:1355:14
at /media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:665:9
at handleIncomingPacket (/media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:762:9)
at Socket.readFromStdout (/media/naval/Data/IIIT/Year 2/Sem 2/DASS/OfficialRepo/Source Code/oyh/node_modules/esbuild/lib/main.js:632:7)
at Socket.emit (node:events:520:28)
at addChunk (node:internal/streams/readable:315:12)
–
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.