Module not found 'child_process'
See original GitHub issueI am getting this error while I try to run it with Next.js
My question is Can we use truffle-hdwallet-provider
in front end apps? Or Is it strictly to use in the backend? I understand the mnemonics, private keys that I get to share in browser but whatsoever for testing purposes I wanted to use. this is giving me the following error
./node_modules/truffle-hdwallet-provider/dist/index.js
Module not found: Can't resolve 'child_process' in '/home/user/Work/projectName/node_modules/truffle-hdwallet-provider/dist'
My package.json
{
"name": "kickstarter",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "mocha",
"dev": "next dev"
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"fs-extra": "^7.0.1",
"ganache-cli": "^6.4.3",
"mocha": "^6.1.4",
"next": "^8.1.0",
"react": "^16.8.6",
"react-dom": "^16.8.6",
"solc": "^0.5.7",
"truffle-hdwallet-provider": "^1.0.7",
"web3": "^1.0.0-beta.37"
}
}
My web3.js file
import Web3 from 'web3';
import * as HDWalletProvider from 'truffle-hdwallet-provider';
const provider = new HDWalletProvider(
'12 weods mnemonics',
'infura/api/url'
);
const web3 = new Web3(provider);
export default web3;
Issue Analytics
- State:
- Created 4 years ago
- Comments:19 (9 by maintainers)
Top Results From Across the Web
Module not found: Error can't resolve 'child_process', how to fix?
But as soon as I try to use child process, using 'require("child_process")' I get the following error when trying to build the extension....
Read more >Module not found: Can't resolve 'child_process' error [Solved]
The error "Module not found: Error: Can't resolve 'child_process'" occurs because there has been a breaking change in Webpack version 5. To solve...
Read more >Module not found: Can't resolve 'child_process' #192 - GitHub
error whenever I try to use node-notifier. I'm using Node v6.11.2 and the code is copy-paste from the examples. Any ideas?
Read more >Module not found: Error can't resolve in react - YouTube
The following issues are handled:1. Module not found : Error can't resolve ' child_process '2. Uncaught ReferenceError: the process is not ...
Read more >cannot find module 'child_process' or its corresponding type ...
I am having an issue with my child process, which is not recognizing the 'tsconfig' file ... These errors both occur because of...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Experienced a similar error with module
child_process
and alsonet
with and Angular application. Solved it by adding topackage.json
:Ok thanks, I’ll try to investigate and see if I come up with anything!