SpringBoot Vue Template Jwt

screenshot of SpringBoot Vue Template Jwt

SpringBoot Vue Template Jwt

SpringBoot 3 + Vue3 前后端分离项目模版,已实现登录注册,限流等功能,可直接上手编写业务

Overview:

The 前后端分离项目(JWT方案)is a template project for building a front-end and back-end separated application using SpringBoot3 and Vue3. It integrates multiple technology stacks and implements the JWT authentication scheme. The back-end functionality includes user registration, user login, password reset, and corresponding API endpoints. It uses Mybatis-Plus as the persistence layer framework and Redis for storing registration/reset operation verification codes with expiration time control. RabbitMQ is used for queuing and sending SMS notifications, which are then processed by a listener. SpringSecurity is utilized as the authorization framework, with manual integration of the JWT validation scheme. Redis is also used for IP address rate limiting to prevent abuse. The view layer objects and data layer objects are separated, and utility methods are implemented to quickly convert between them using reflection. Error and exception pages are uniform and returned in JSON format. Cross-origin requests are handled manually using filters. Swagger is used for automatic generation of API documentation, with pre-configured login-related endpoints. Filters are also employed to automatically generate snowflake IDs for all requests, making it easier to identify and locate issues in the production environment. The project supports multiple environments and has different configurations for development and production. The log files contain complete information about each request as well as their corresponding snowflake IDs. The overall project structure is clear, responsibilities are well-defined, and comprehensive documentation is provided. It is ready to use out-of-the-box. On the front-end side, the project includes user registration, user login, password reset interfaces, and a simple homepage. It utilizes Vue-Router for routing, Axios for asynchronous requests, Element-Plus as the UI component library, and VueUse to adapt to dark mode switching. It also uses unplugin-auto-import to reduce the bundle size by selectively importing components.

Features:

  • Front-end Features:

    • User registration, user login, and password reset interfaces
    • Simple homepage
    • Vue-Router for routing
    • Axios for asynchronous requests
    • Element-Plus as the UI component library
    • VueUse for adapting to dark mode switching
    • unplugin-auto-import for selective component import to reduce bundle size
  • Back-end Features:

    • User registration, user login, and password reset functionality
    • Mybatis-Plus as the persistence layer framework
    • Redis for storing registration/reset operation verification codes with expiration time control
    • RabbitMQ for queuing and sending SMS notifications, processed by a listener
    • SpringSecurity as the authorization framework with manual JWT validation integration
    • Redis for IP address rate limiting