Skip to content

franklsm1/spring-react

Repository files navigation

Spring-react Example App

A single project that combines a react/redux front end with a spring boot backend running on one server.

When building this application the front end component will be minified to static files and bundled up into a jar. The backend will then use that frontend jar at runtime and serve it when the application is opened in a browser.

Setup project:

  1. Run npm install -g yarn to install Yarn(a better npm) globally
  2. Clone the repo using git clone
  3. cd into the project

Complete install, build, and packaging of both the front and back-end components

  1. Run gradle to build everything and run all tests

Build, test, minify, and create a jar of the front-end code

  1. Run gradle buildFrontend

Build, test, and create a jar of the backend-end code (front end needs to be build first)

  1. Run gradle build

Build, test, and start front-end with a mock back-end using json-server

  1. Run gradle startFrontend
  2. Navigate to: localhost:3000

Start full stack application after a build

  1. Run gradle bootrun
  2. Navigate to: localhost:8080

Helpful Links

  • Link to react-router example used for frontend piece

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published