/todo_app

Todo app in react and spring boot

Primary LanguageJava

Spring Boot React Template

A template to create a monolithic Spring Boot app with a reactjs based front-end.

This repository provides a temnplate for a full stack solution for a Java spring boot API with a react based front-end. This repository presents a monolithic web app based full stack solutions. Building microservices is often considered the norm these days, however monolithic apps still have valid uses for which they can be used, one example being, when doing proof of concept for a new product.

Have a read of this blogpost for a walkthrough of this solution.

Details for the Spring Boot API

A simple spring boot based REST API that can CRUD's data for accounts for customers.

API structure

  1. a basic CRUD API for a resource i.e. account
    • maintain a simple structure without relying too much on certain design patterns
    • saves data to a in-memory list
  2. react based front-end that sends data back and forth
    • keep all logic in the one app.js file
    • don't worry about writing unit tests for rect based UI
  3. postman tests to validate the Spring Boot API
    • ensure postman tests are checked in the source code

Details for the react based SPA

Added a simple react based app that allows you to CRUD data to the backend API from the frontend. The UI is simple and self-explanatory. The purpose of the UI is to demonstrate certain concepts of UI integration with a spring boot app.

Build Plugin

To build a react app and launch it when running mvn spring-boot:run, the frontend-maven-plugin is used. Have a look at the pom file to know more.

More great tutorials and code samples

I will be writing a detailed tutorial on how to work with this repo on my blog. Until then refer to my blog for other tutorials and "how-to" articles with detailed code samples.

If you like what I am doing, you can buy me a coffee