Skip to content

chaitu1969/Prime-Reel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

22 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸŽ₯ Prime Reel

Welcome to Prime Reel β€” a sleek, responsive movie app built with React, leveraging TMDB API for movie data and OpenAI GPT API for AI-powered search recommendations. Whether you’re here to browse trending movies, play trailers, or explore AI-powered suggestions, Prime Reel offers it all with a smooth user experience!

Check it out live: Prime Reel
GitHub Repository: Prime Reel GitHub


πŸŽ₯ Prime Reel

Welcome to Prime Reel β€” a sleek, responsive movie app built with React, leveraging TMDB API for movie data and OpenAI GPT API for AI-powered search recommendations. Whether you’re here to browse trending movies, play trailers, or explore AI-powered suggestions, Prime Reel offers it all with a smooth user experience!

Check it out live: Prime Reel
GitHub Repository: Prime Reel GitHub


⚠️ Note

  • Prime Reel may not work on the Jio network in India due to certain network restrictions. Please try accessing the site using a different network if you encounter issues.

🌟 Features

  • User Authentication

    • Login & Signup Forms with Form Validation
    • User authentication powered by Firebase
    • Redux store integration for managing user sessions
    • Update user profile with display name and profile picture
    • Auto-redirect: If not logged in, users are sent to the login page
  • Movie Browsing

    • Displays Now Playing, Popular, and Trending Movies using custom React hooks
    • Embedded YouTube trailers with autoplay and mute for a cinematic experience
    • TailwindCSS-based design for a clean, responsive UI
  • AI Search Recommendations

    • AI-powered Search Page using OpenAI GPT API
    • Get movie suggestions based on your input
    • Fetch and display recommended movies in a reusable movie list component

    • Auto-redirect: If not logged in, users are sent to the login page
  • Movie Browsing

    • Displays Now Playing, Popular, and Trending Movies using custom React hooks
    • Embedded YouTube trailers with autoplay and mute for a cinematic experience
    • TailwindCSS-based design for a clean, responsive UI
  • AI Search Recommendations

    • AI-powered Search Page using OpenAI GPT API
    • Get movie suggestions based on your input
    • Fetch and display recommended movies in a reusable movie list component

πŸš€ Project Setup & Deployment

  1. Clone the Repository:

=======

  1. Clone the Repository:

    git clone https://github.com/chaitu1969/Prime-Reel.git
    cd Prime-Reel
  2. Install Dependencies:

npm install
  1. Configure TailwindCSS:
    Set up Tailwind using postcss.config.js and tailwind.config.js.

  2. Firebase Setup:

  • Create a Firebase project.
  • Add Firebase configuration to .env file.
  • Deploy with:
    npm run build
    firebase deploy
  1. TMDB API Setup:
  • Register at TMDB and get an API key.
  • Add the API key to constant.js.
  1. OpenAI GPT Setup:

  2. TMDB API Setup:

    • Register at TMDB and get an API key.
    • Add the API key to constant.js.
  3. OpenAI GPT Setup:

    • Get your OpenAI API key and configure it in the .env file.
    • Use it to fetch AI-powered movie recommendations.

πŸ“‚ Project Structure

/src
 β”œβ”€β”€ components/
 β”‚   β”œβ”€β”€ Header.js
 β”‚   β”œβ”€β”€ LoginForm.js
 β”‚   β”œβ”€β”€ MovieCard.js
 β”‚   β”œβ”€β”€ MovieList.js
 β”‚   β”œβ”€β”€ AIRecommendation.js
 β”œβ”€β”€ hooks/
 β”‚   β”œβ”€β”€ useNowPlayingMovies.js
 β”‚   β”œβ”€β”€ usePopularMovies.js
 β”‚   β”œβ”€β”€ useTrendingMovies.js
 β”œβ”€β”€ redux/
 β”‚   β”œβ”€β”€ userSlice.js
 β”‚   β”œβ”€β”€ movieSlice.js
 β”‚   β”œβ”€β”€ gptSlice.js
 β”œβ”€β”€ constants/
 β”‚   └── constant.js
=======
Prime-Reel/
β”‚
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ components/                 # UI components of the application
β”‚   β”‚   β”œβ”€β”€ Body.js                 # Main body of the homepage
β”‚   β”‚   β”œβ”€β”€ Browse.js               # Browse page to explore movies
β”‚   β”‚   β”œβ”€β”€ gptMovieSuggestion.js   # GPT-based movie suggestion logic
β”‚   β”‚   β”œβ”€β”€ GptSearch.js            # Search component powered by GPT
β”‚   β”‚   β”œβ”€β”€ gptSearchBar.js         # Input bar for GPT movie search
β”‚   β”‚   β”œβ”€β”€ Header.js               # Header component with navigation links
β”‚   β”‚   β”œβ”€β”€ Login.js                # Login page
β”‚   β”‚   β”œβ”€β”€ MainContainer.js        # Primary container for the app layout
β”‚   β”‚   β”œβ”€β”€ MovieCard.js            # Component displaying a movie card
β”‚   β”‚   β”œβ”€β”€ MovieList.js            # Component rendering a list of movies
β”‚   β”‚   β”œβ”€β”€ SecondaryContainer.js   # Secondary section container
β”‚   β”‚   β”œβ”€β”€ VideoBackground.js      # Component for video background
β”‚   β”‚   └── VideoTitle.js           # Component for video title display
β”‚   β”‚
β”‚   β”œβ”€β”€ hooks/                      # Custom hooks for stateful logic
β”‚   β”‚   β”œβ”€β”€ useMovieTrailer.js      # Hook to fetch movie trailers
β”‚   β”‚   β”œβ”€β”€ useNowPlayingMovies.js  # Hook to fetch now-playing movies
β”‚   β”‚   β”œβ”€β”€ usePopularMovies.js     # Hook to fetch popular movies
β”‚   β”‚   └── useTopRatingMovies.js   # Hook to fetch top-rated movies
β”‚   β”‚
β”‚   β”œβ”€β”€ utils/                      # Utility functions and configs
β”‚   β”‚   β”œβ”€β”€ appStore.js             # Redux store configuration
β”‚   β”‚   β”œβ”€β”€ auth.js                 # Firebase authentication logic
β”‚   β”‚   β”œβ”€β”€ constants.js            # Application-wide constants
β”‚   β”‚   β”œβ”€β”€ firebase.js             # Firebase initialization
β”‚   β”‚   β”œβ”€β”€ gptSlice.js             # Redux slice for GPT data
β”‚   β”‚   β”œβ”€β”€ movieSlice.js           # Redux slice for movie data
β”‚   β”‚   β”œβ”€β”€ openai.js               # OpenAI API configuration
β”‚   β”‚   β”œβ”€β”€ userSlice.js            # Redux slice for user data
β”‚   β”‚   └── validate.js             # Validation utilities
β”‚   β”‚
β”‚   β”œβ”€β”€ App.css                     # Global CSS for the app
β”‚   β”œβ”€β”€ App.js                      # Root component of the React app
β”‚   β”œβ”€β”€ index.css                   # Base styles for the app
β”‚   └── index.js                    # Entry point of the React app
β”‚
β”œβ”€β”€ .env                            # Environment variables
β”œβ”€β”€ .firebaserc                     # Firebase project configuration
β”œβ”€β”€ .gitignore                      # Ignored files for Git
β”œβ”€β”€ firebase.json                   # Firebase hosting configuration
β”œβ”€β”€ package-lock.json               # Dependencies lock file
β”œβ”€β”€ package.json                    # Project dependencies and scripts
β”œβ”€β”€ tailwind.config.js              # TailwindCSS configuration
└── README.md                       # Project documentation

>>>>>>> f85647b2090ed0a79757b770e1fc91e6da934bb7

🎯 Key Implementations

  1. Redux Store:

    • Manage user sessions using userSlice.
    • Store movie and trailer data efficiently using Redux slices.
  2. Routing and State Management:

    • Use react-router-dom for seamless routing.
    • Implemented memoization to optimize component re-renders.
  3. Custom Hooks:

    • useNowPlayingMovies, usePopularMovies, and useTrendingMovies for fetching movie data.
    • Subscriptions handled properly with unsubscribe on component unmount (in Header.js).
  4. YouTube Embedding:

  5. Redux Store:

    • Manage user sessions using userSlice.
    • Store movie and trailer data efficiently using Redux slices.
  6. Routing and State Management:

    • Use react-router-dom for seamless routing.
    • Implemented memoization to optimize component re-renders.
  7. Custom Hooks:

    • useNowPlayingMovies, usePopularMovies, and useTrendingMovies for fetching movie data.
    • Subscriptions handled properly with unsubscribe on component unmount (in Header.js).
  8. YouTube Embedding:

    • Fetch trailer data from TMDB.
    • Play trailers seamlessly with embedded YouTube players.

πŸ›  Tech Stack

  • Frontend: React, Redux, TailwindCSS
  • Authentication & Hosting: Firebase
  • API Integrations:
    • TMDB API for movie data
    • OpenAI GPT API for AI-based recommendations
  • State Management: Redux Toolkit
  • Routing: React Router

  • Frontend: React, Redux, TailwindCSS
  • Authentication & Hosting: Firebase
  • API Integrations:
    • TMDB API for movie data
    • OpenAI GPT API for AI-based recommendations
  • State Management: Redux Toolkit
  • Routing: React Router

πŸ“ˆ Future Plans

  • Enhance the Main Container for better movie organization.
  • Add user preferences to personalize movie recommendations.
  • Implement offline caching for better performance.
  • Add dark mode support for improved user experience.

  • Enhance the Main Container for better movie organization.
  • Add user preferences to personalize movie recommendations.
  • Implement offline caching for better performance.

πŸ“‹ Installation Notes

  • Don't forget to create a .env file with the following keys:

    REACT_APP_FIREBASE_API_KEY=<your-firebase-api-key>
    REACT_APP_TMDB_API_KEY=<your-tmdb-api-key>
    REACT_APP_OPENAI_API_KEY=<your-openai-api-key>
    
  • Add .env to .gitignore to avoid exposing sensitive information.


🎬 Screenshots

Add relevant screenshots or GIFs here to visually represent the app!


πŸ“ Contributing

=======

REACT_APP_FIREBASE_API_KEY=<your-firebase-api-key>
REACT_APP_TMDB_API_KEY=<your-tmdb-api-key>
REACT_APP_OPENAI_API_KEY=<your-openai-api-key>
  • Add .env to .gitignore to avoid exposing sensitive information.

πŸ“ Contributing

Contributions are welcome! Feel free to submit a pull request or open an issue to improve the app.


πŸ“„ License

This project is licensed under the MIT License. See the LICENSE file for more details.


πŸ’‘ Contact

Developed by Chaitanya Karle. Feel free to connect for collaboration opportunities!
LinkedIn: Chaitanya Karle
Email: chaitanya.karle@gmail.com


Enjoy exploring movies with Prime Reel! 🍿

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors