AbhyudayaSharma / react-git-info

Get Git commit information in your React App

Home Page:https://www.npmjs.com/package/react-git-info

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

getting 4 5 issues like ,, /node_modules/react-git-info/src/GitInfo.macro.js Module not found: Error: Can't resolve 'child_process' in

nadeem53367 opened this issue · comments

react_devtools_backend.js:2574 ./node_modules/cosmiconfig/dist/readFile.js
Module not found: Error: Can't resolve 'fs' in 'C:\Users\Admin\Desktop\myproject\node_modules\cosmiconfig\dist'
------
react_devtools_backend.js:2574 ./node_modules/import-fresh/node_modules/resolve-from/index.js
Module not found: Error: Can't resolve 'fs' in 'C:\Users\Admin\Desktop\myproject\node_modules\import-fresh\node_modules\resolve-from'
------
/node_modules/path-type/index.js
Module not found: Error: Can't resolve 'fs' in 'C:\Users\Admin\Desktop\myproject\node_modules\path-type'
----------
/node_modules/resolve/lib/async.js
Module not found: Error: Can't resolve 'fs' in 'C:\Users\Admin\Desktop\swift projects\swift-frontend\node_modules\resolve\lib'

Hi @nadeem53367. The information you've provided is not sufficient to recreate this issue. child_process and fs are provided by node and should be available in all valid node installations. Please let me know your OS, node, npm, create-react-app, and react-git-info versions, package.json, and directory structure. Without these, I don't think I would be able to provide any help.

Hi. I'm closing this issue now. This looks like a problem with your node installation. If you still encounter errors, please create a new issue containing steps to replicate. Thanks.

hi @AbhyudayaSharma, What would be the steps to implement this, if i am NOT using CRA, i have node, yarn, git everything installed
I am getting the same errors, also eslint is complaining about using the dev dependency and recommend using it as a main dep.

Can you please help?

I am also running into the same problem - did you ever resolve this? @shoaibmohommed