https://github.com/sandesh300/angular-reddit-clone
Reddit-Clone web application using Angular (frontend). Spring Security with JWT Authentication, Spring Data JPA with MySQL, Spring MVC.
https://github.com/sandesh300/angular-reddit-clone
angular css html
Last synced: 2 months ago
JSON representation
Reddit-Clone web application using Angular (frontend). Spring Security with JWT Authentication, Spring Data JPA with MySQL, Spring MVC.
- Host: GitHub
- URL: https://github.com/sandesh300/angular-reddit-clone
- Owner: sandesh300
- Created: 2023-07-17T17:53:31.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2024-03-11T19:31:20.000Z (over 2 years ago)
- Last Synced: 2025-04-14T00:50:06.234Z (about 1 year ago)
- Topics: angular, css, html
- Language: TypeScript
- Homepage:
- Size: 160 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# AngularRedditClone
# Reddit-Clone-Backend
## Introduction -
This project is a Reddit-Clone web application developed using Spring Boot. It provides users with functionalities similar to Reddit, allowing them to create posts, comment on posts, upvote/downvote posts and comments, and more. The application also incorporates Spring Security with JWT Authentication for secure user authentication and authorization.
## Technologies -
- Spring Boot: Framework for building Java-based web applications.
- Spring Security: Provides authentication, authorization, and other security features.
- Spring Data JPA: Simplifies data access and manipulation by providing repositories and entity management.
- Angular: To build a beautiful user interface.
- MySQL: Relational database management system for storing application data.
- Spring MVC: Architecture for building web applications based on the Model-View-Controller pattern.
## Features -
- User Registration: Allows users to create new accounts with unique usernames and passwords.
- User Authentication: Secure authentication using JWT tokens.
- Post Creation: Users can create new posts with titles, content, and categories.
- Commenting: Users can comment on posts and reply to existing comments.
- Voting System: Users can upvote or downvote posts and comments.
- Search Functionality: Enables users to search for posts by title or category.
- Pagination: Efficiently handles large amounts of content by dividing it into pages.
## Architectures -
The application follows a standard MVC architecture:
- Model: Represents the data and business logic of the application. Entities and repositories are managed using Spring Data JPA.
- View: Defines the presentation layer of the application. Thymeleaf templates or frontend frameworks can be used for rendering HTML pages.
- Controller: Handles user requests, performs necessary operations, and returns appropriate responses. Controllers are responsible for interacting with services and repositories.
## Modules -
The key modules of the application include:
1. Authentication Module: Handles user authentication and authorization using Spring Security and JWT tokens.
2. Post Module: Manages the creation, retrieval, updating, and deletion of posts.
3. Comment Module: Handles comments associated with posts and provides functionalities for adding, viewing, and deleting comments.
4. Vote Module: Implements the voting system for posts and comments, allowing users to upvote or downvote content.
## MySQL Table Schema -
Below is the simplified schema for the MySQL database used in this project:
1. User Table:
- user_id (Primary Key)
- username
- password (hashed)
- email
- created_at
2. Post Table:
- post_id (Primary Key)
- title
- content
- category
- user_id (Foreign Key)
- created_at
3. Comment Table:
- comment_id (Primary Key)
- content
- post_id (Foreign Key)
- user_id (Foreign Key)
- created_at
4. Vote Table:
- vote_id (Primary Key)
- vote_type (ENUM: UPVOTE, DOWNVOTE)
- post_id (Foreign Key)
- comment_id (Foreign Key)
- user_id (Foreign Key)
# Images -
## Home Page -

## Sign Up page -

## Create Sub Reddit Page -

## Create Post Pages -


## Development server
Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.
## Code scaffolding
Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.
## Build
Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `--prod` flag for a production build.
## Running unit tests
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
## Running end-to-end tests
Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).
## Further help
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).