dmitryblackwell / spring-react-template

Template for spring and react apps with jwt auth.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

spring-react-template

About this project

This is template for spring-react application with authorization by Json Web Token (JWT). When I was learning authorization in SPA it was difficult to find any working example. So I created my own. This is simple project with authorization, home page and logout.

Contribute to this project

If you find something that can be improved, please, open an issue, so I can fix it.

Or you can fix it on your own and suggest a pull request to me.

Thank you, in advance.

Getting started

For this project you need to install npm and jdk. Dont forget to setup system variables.

git clone https://github.com/dmitryblackwell/spring-react-template.git
cd spring-react-template
mvnw spring-boot:run -P prod

-P prod means that app is going to run under prod maven profile with maven frontend. This plugin automatically install node_modules and create bundle.js for website.

If you want to run it for development purposes than you need to import it your IDE and run

  1. SpringReactTemplateApplication for spring web api.
  2. Webpack dev server for automatic rendering your fronted part - npm start.

Tech Stack

Backend:

  1. Spring Boot
  2. Spring Data
  3. Spring Security
  4. Hibernate ORM

Frontend:

  1. React
  2. React Hooks
  3. Webpack

About

Template for spring and react apps with jwt auth.


Languages

Language:Java 63.8%Language:JavaScript 30.7%Language:HTML 3.7%Language:CSS 1.8%