ReactJS-AdminLTE icon indicating copy to clipboard operation
ReactJS-AdminLTE copied to clipboard

Can't get it to work with 'react create app'

Open Tsury opened this issue 8 years ago • 15 comments
trafficstars

EDIT: I mean 'create-react-app'...

I'm following the usage instructions but I'm getting errors in the main js file of ReactJS-AdminLTE saying that react-dom and velocity are missing.

These are the errors I am getting:

Failed to compile.

Error in ./~/adminlte-reactjs/reactjsAdminlte.js
Module not found: 'reactDom' in C:\myApp\node_modules\adminlte-reactjs

 @ ./~/adminlte-reactjs/reactjsAdminlte.js 1:120-139

Error in ./~/adminlte-reactjs/reactjsAdminlte.js
Module not found: 'velocity' in C:\myApp\node_modules\adminlte-reactjs

 @ ./~/adminlte-reactjs/reactjsAdminlte.js 1:140-159

Could that be something with the webpack config not being used? I see that there's aliases there for react-dom and velocity and paths to get the libraries from.

Tsury avatar Jan 11 '17 21:01 Tsury

The same

un000 avatar Jan 21 '17 17:01 un000

I tried to report it on 'create-react-app' and this is the response I got: https://github.com/facebookincubator/create-react-app/issues/1380

Tsury avatar Jan 22 '17 08:01 Tsury

Thank you so much for this @Tsury , I understand the issue now. Will fix asap.

booleanhunter avatar Jan 22 '17 14:01 booleanhunter

Thank you! Once you finish, can you please add some instructions on how to successfully integrate with 'create-react-app'? Thanks again.

Tsury avatar Jan 22 '17 14:01 Tsury

Sure I will!

booleanhunter avatar Jan 22 '17 14:01 booleanhunter

Same problem here, any ideas?

EduardoOliveira avatar Oct 27 '17 09:10 EduardoOliveira

+1

aftabnaveed avatar Feb 27 '18 09:02 aftabnaveed

I have same problem as well

./node_modules/adminlte-reactjs/node_modules/react-dom/lib/ReactDOMUnknownPropertyHook.js Module not found: Can't resolve 'react/lib/ReactComponentTreeHook' in '/home/caprice/Documents/gvp_ui/node_modules/adminlte-reactjs/node_modules/react-dom/lib'

suryacaprice avatar Mar 06 '18 13:03 suryacaprice

I got the same problem here

ramonberrutti avatar Apr 05 '18 18:04 ramonberrutti

I also have the same issue

Netsoro avatar Apr 14 '18 17:04 Netsoro

I think the issue is that npm version is outdated.

npm package.json

"react": "^0.14.8",
"react-dom": "^15.4.2",

github repo package.json

"react": "^16.3.2",
"react-dom": "^16.3.2"

So for now I changed the path in my package.json to "adminlte-reactjs": "git+https://github.com:booleanhunter/ReactJS-AdminLTE.git" and it seems to work.

orangecoloured avatar May 12 '18 09:05 orangecoloured

The React npm version is exactly what was wrong for me. Changing the path the git makes all the difference. Any idea when a new NPM will be posted?

treetopvt avatar May 12 '18 11:05 treetopvt

@booleanhunter Any new updates for it to work with create-react-app

sabbiu avatar Jul 02 '18 07:07 sabbiu

I'll be committing some major changes to this repo in a couple of weeks. Will be using create-react-app so you wouldn't have to bother with Webpack and other dependency issues.

booleanhunter avatar Aug 03 '18 18:08 booleanhunter

I'll be committing some major changes to this repo in a couple of weeks. Will be using create-react-app so you wouldn't have to bother with Webpack and other dependency issues.

Hi Sir, Have the changes occurred?

thierabsy avatar Oct 16 '18 21:10 thierabsy