Skip to content

Commit 794f023

Browse files
author
zead sayed
committed
feat: redesign app and organize feature architecture
1 parent bd254a2 commit 794f023

112 files changed

Lines changed: 4225 additions & 1632 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,21 @@ Live demo: https://zeadsayed.github.io/movie-DB/
66

77
## Features
88

9-
- User authentication (login/register) with form validation
9+
- User login with DummyJSON authentication and form validation
1010
- Route guards to protect authenticated pages
1111
- Feature/data services for API communication
1212
- Reactive state and data flow with RxJS
1313
- Movie data fetched from an external API
14+
- Global TMDB multi-search and filtered discovery
15+
- Trailers, cast, recommendations, streaming providers, and person filmographies
16+
17+
## TMDB configuration
18+
19+
TMDB requests are centralized in `TmdbService`. The `TmdbInterceptor` adds the API key from the Angular environment configuration, so credentials are not duplicated in services or request URLs.
20+
21+
Before running the app, add your own TMDB API key to `tmdbApiKey` in `src/environments/environment.ts`. Keep real credentials out of commits and public repositories.
22+
23+
Because Angular environment values are compiled into the browser bundle, they are not secret. Use a backend proxy if your deployment requires the TMDB credential to remain private.
1424

1525
## Tech stack
1626

@@ -19,6 +29,32 @@ Live demo: https://zeadsayed.github.io/movie-DB/
1929
- RxJS
2030
- HTML/CSS
2131

32+
## Project structure
33+
34+
```text
35+
src/app/
36+
├── core/ # Singleton services, guards, interceptors, and data models
37+
│ ├── guards/
38+
│ ├── interceptors/
39+
│ ├── models/
40+
│ └── services/
41+
├── features/ # Route-level product features
42+
│ ├── movies/
43+
│ ├── tv-shows/
44+
│ ├── discover/
45+
│ ├── people/
46+
│ └── watchlist/
47+
├── layout/ # App-wide visual shell components
48+
│ ├── navbar/
49+
│ ├── header/
50+
│ └── footer/
51+
├── app-routing.module.ts
52+
├── app.component.*
53+
└── app.module.ts
54+
```
55+
56+
Feature code stays together, application-wide state and API infrastructure live under `core`, and components that construct the site shell live under `layout`.
57+
2258
## Getting started
2359

2460
```bash

angular.json

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,16 +37,24 @@
3737
},
3838
"configurations": {
3939
"production": {
40+
"optimization": {
41+
"scripts": true,
42+
"styles": {
43+
"minify": true,
44+
"inlineCritical": false
45+
},
46+
"fonts": true
47+
},
4048
"budgets": [
4149
{
4250
"type": "initial",
43-
"maximumWarning": "500kb",
44-
"maximumError": "1mb"
51+
"maximumWarning": "950kb",
52+
"maximumError": "1100kb"
4553
},
4654
{
4755
"type": "anyComponentStyle",
48-
"maximumWarning": "2kb",
49-
"maximumError": "4kb"
56+
"maximumWarning": "8kb",
57+
"maximumError": "10kb"
5058
}
5159
],
5260
"outputHashing": "all"

package-lock.json

Lines changed: 10 additions & 36 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/app/about/about.component.css

Lines changed: 0 additions & 110 deletions
This file was deleted.

src/app/about/about.component.html

Lines changed: 0 additions & 47 deletions
This file was deleted.

0 commit comments

Comments
 (0)