spring-attic / tut-react-and-spring-data-rest

React.js and Spring Data REST :: A tutorial based on the 5-part blog series by Greg Turnquist
https://spring.io/guides/tutorials/react-and-spring-data-rest
883 stars 1.58k forks source link

Can not run the project on Spring Source Tool Suite. #123

Open vosybac opened 4 years ago

vosybac commented 4 years ago

I am newbie of Spring and ReactJs. I have learned Spring and ReactJs but haven't integrated them together. I can not run the project on Sprint Source Tool Suite. Please help. Thanks in advance!

dsyer commented 4 years ago

I don't know anything about React. I cloned the repo and ran mvn install in the basic sample, then imported it into STS. Ran the main method and went to localhost:8080 in the browser. All 200 OK as far as I can see. I don't really know what it was supposed to do, but it shows a table of employees (actually only one). Seems like it works to me?

vosybac commented 4 years ago

I got this error when ran mvn install

[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.6:npm (npm install) on project react-and-spring-data-rest-basic: Failed to run task: 'npm install' failed. java.io.IOException: Cannot run program "C:\Users\B\Desktop\SpringProjects\tut-react-and-spring-data-rest-master\tut-react-and-spring-data-rest-master\basic\target\node\node.exe" (in directory "C:\Users\B\Desktop\SpringProjects\tut-react-and-spring-data-rest-master\tut-react-and-spring-data-rest-master\basic"): CreateProcess error=193, %1 is not a valid Win32 application -> [Help 1] [ERROR]

Buzzardo commented 4 years ago

Do you have Cygwin? If so, does it run correctly if you try it on Cygwin?

dsyer commented 4 years ago

I think the mvnw.* scripts were old and mouldy. I replaced them with fresh downloads from start.spring.io. Maybe it works now (on the command line at least)?