A YouTube-like platform developed using HTML, CSS, JavaScript, and React.js

Youtube-clone Live

logo

Screenshot of the ApplicationScreenshot of the ApplicationScreenshot of the Application

Table of content ๐Ÿ“

  1. Features
  2. Tech Stack
  3. Getting Started
  4. Understand Context Api
  5. Contribute

1. Features ๐ŸŽฏ

1. Infinite Scrolling


2. Modern Dark Theme


3. Loading UI


4. Country Option ๐ŸŒ


5. Autocomplete Search Bar


6. Mobile Responsive


2. Tech Stack

  1. โš›๏ธ ReactJS โ€“ A popular JavaScript library for building user interfaces, known for its component-based architecture and efficient rendering.
  2. ๐Ÿ’Ž Chakra UI โ€“ A flexible and accessible UI component library for React that makes it easy to create visually appealing and responsive user interfaces.
  3. Packages

3. Getting Started โ–ถ๏ธ

Follow these steps to set up and run the project on your local machine.

1. Clone the Repository

To get a local copy of this repository, run the following command in your terminal:

git clone https://github.com/divyaGrvgithub/YouTube-Clone

2. Navigate to the Project

Change your working directory to the project folder:

cd YouTube-Clone

3. Install Dependencies

Install the required packages using npm:

npm i
npm i -D tailwindcss

4. API KEY Setup

To fetch YouTube data, youโ€™ll need the following API_KEYS. Follow these steps to set them up:

  1. Obtain a YouTube API key from Google by visiting Google Developers โ€“ Getting Started. If you need detailed instructions, you can also refer to How to Get a YouTube API Key.
  2. Get a YouTube V3 API key from Rapid API โ€“ YouTube V3. If you havenโ€™t used Rapid API before, youโ€™ll need to sign up after signup subscribe to the YouTube V3 API for free.

Once you have your API keys, proceed with the following:

  1. Create a .env file in the root directory of your project.
  2. Place your API key values in the .env file as shown below. Note that Iโ€™ve included two Google API keys as backups in case one exceeds its usage limits.
REACT_APP_YOUTUBE_API_KEY_GOOGLE1=YOUR_API_KEY
REACT_APP_YOUTUBE_API_KEY_GOOGLE2=YOUR_API_KEY
REACT_APP_YOUTUBE_API_KEY_RAPIDAPI=YOUR_API_KEY
Note :- The REACT_APP prefix is used to define environment variables in a React application. These variables are used during the build process and can be accessed in your code using process.env.REACT_APP_VARIABLE_NAME.

5. Start the Project

Run the following command to launch the ReactJS project in your local environment:

npm start

6. Access the Project

Open your web browser and go to http://localhost:3000 to view the project.

Thatโ€™s it! Youโ€™re now ready to explore the project locally.

Happy coding! ๐Ÿš€

โญ๏ธIf youโ€™ve found value in this, a star would be a wonderful way to say thanks..


4. Understand Context API ๐Ÿง 

YoutubeContext.js is a context module designed to simplify the management of YouTube data in your React application. It leverages the power of Reactโ€™s Context API to provide a centralized state and functions for fetching and handling YouTube data.

Key Features:

  • Fetch trending videos based on country code.
  • Perform autocomplete suggestions for search queries.
  • Retrieve search results for videos based on user queries.
  • Efficiently handle API calls and loading states.
  • I have incorporated a second API for generateAutocomplete suggestions due to the first APIโ€™s lack of mobile screen support. However, the first API offers unlimited access on desktop, which is why I decided to utilize both.
  • For the functions getSearchVideos and getTrendingVideo, I implemented the second API as a backup. This arrangement ensures that when the first API exceeds its usage limit, the second API can seamlessly take over and provide uninterrupted service. This approach enhances the reliability of the application and provides a smooth user experience.

5. How to Contribute ๐Ÿค

Thank you for considering contributing to this project! Your contributions make a real difference and help improve this project for everyone. Here are a few ways you can get involved:

  • Report Bugs: If you come across any bugs or issues, please open an issue to let us know. Be sure to provide as much detail as possible.
  • Suggest Enhancements: Have an idea to make this project even better? Feel free to create an issue to share your enhancement suggestions.
  • Submit Pull Requests: If youโ€™re technically inclined, you can submit a pull request with code changes. Make sure to follow our coding guidelines and explain the purpose of your pull request.
  • Spread the Word: If you love this project, a simple star or sharing it with others can make a big difference.

We value every contribution, big or small, and appreciate your support in making this project better for the entire community. Thank you for being a part of it!

GitHub

View Github

Related Posts

Popular Posts

BrowserVideoEdit: A feature-rich video editor created using fabric.js and Next.js, all within the convenience of your web browser

A weather app that allows users to view real-time weather information based on their locations

Add Login and Register page into your Nuxt 3 project using Supabase authentication

A powerful Flutter package that allows you to easily create and control glitch effects

เด’เดฐเต‡เดฆเดฟเดตเดธเด‚ เดฐเดฃเตเดŸเตเดชเต‡เดฐเต†เดฏเตเด‚ เดชเต†เดฃเตเดฃเตเด•เดฃเตเดŸเต, เด•เต‹เดŸเตเดŸเดฏเด‚ เดชเต‚เดžเตเดžเดพเดฐเตโ€ เดธเตเดตเดฆเต‡เดถเดฟเดฏเดพเดฏ เดฆเดจเตเดคเดกเต‹เด•เตเดŸเดฑเตเดฎเดพเดฏเดฟ เดตเดฟเดตเดพเดนเด‚ เดฐเดœเดฟเดธเตเดฑเตเดฑเตผ เดšเต†เดฏเตเดคเต , เดชเดฟเดจเตเดจเต€เดŸเต เดตเต‡เดฃเตเดŸเต†เดจเตเดจเตเดตเต†เดšเตเดšเต.

A Library for Rendering 3D Models in React.js and Next.js Views

Recent Posts

เด‡เดŸเตเด•เตเด•เดฟเดฏเดฟเดฒเต† เดฎเดฒเดฏเต‹เดฐ เดฎเต‡เด–เดฒเด•เดณเดฟเตฝ เดฐเดพเดคเตเดฐเดฟเดฏเดพเดคเตเดฐ เดจเดฟเดฐเต‹เดงเดฟเดšเตเดšเต. เดฐเดพเดคเตเดฐเดฟ เดเดดเต เดฎเตเดคเตฝ เดฐเดพเดตเดฟเดฒเต† เด†เดฑเต เดตเดฐเต†เดฏเดพเดฃเต เดจเดฟเดฐเต‹เดงเดจเด‚

เดเดจเตเดคเดฏเดพเตผ เดˆเดธเตเดฑเตเดฑเดฟเตฝ เดชเตเดฐเดณเดฏเดคเตเดคเดฟเตฝ เดคเด•เตผเดจเตเดจ เดชเดพเดฒเดคเตเดคเดฟเดจเต เดชเด•เดฐเด‚ เดชเตเดคเดฟเดฏ เดชเดพเดฒเด‚ เดจเดฟเตผเดฎเตเดฎเดฟเด•เตเด•เตเดตเดพเตป เดคเดพเดคเตเด•เตเด•เดพเดฒเดฟเด• เดชเดพเดฒเด‚ เดชเตŠเดณเดฟเดšเตเดšเต เดจเต€เด•เตเด•เดฟ

Explore the Investment Opportunities: A Comprehensive Guide to Different Types of Mutual Funds

Title: Understanding Mutual Funds: A Beginner's Guide to Investing

เดคเต€เดตเตเดฐเดฎเดด เดฎเตเดจเตเดจเดฑเดฟเดฏเดฟเดชเตเดชเดฟเดจเตเดฑเต† เดชเดถเตเดšเดพเดคเดฒเดคเตเดคเดฟเตฝ เดธเด‚เดธเตเดฅเดพเดจเด‚ เดœเดพเด—เตเดฐเดคเดฏเดฟเตฝ

250,000 เด…เดชเต‡เด•เตเดทเด•เตพ เดตเตผเดฆเตเดงเดฟเดšเตเดšเดคเดฟเดจเดพเตฝ เดŸเตเดฐเดพเตปเดธเตโ€Œเดชเต‹เตผเดŸเตเดŸเต เด•เดฎเตเดฎเต€เดทเดฃเตผ เดชเดฐเดฟเดถเต‹เดงเดจ เดชเตเดจเดฐเดพเดฐเด‚เดญเดฟเด•เตเด•เตเด‚

เดเดฒเด•เตเด•เดฏเดฟเตฝ เด•เต€เดŸเดจเดพเดถเดฟเดจเดฟ เดธเดพเดจเตเดจเดฟเดงเตเดฏเด‚; เด†เดฑเดฐ เดฒเด•เตเดทเดคเตเดคเดฟเดฒเดงเดฟเด•เด‚ เดŸเดฟเตป เด…เดฐเดตเดฃ เดจเดถเดฟเดชเตเดชเดฟเด•เตเด•เดพเตป เดŸเต†เตปเดกเตผ เด•เตเดทเดฃเดฟเดšเตเดšเต เดฆเต‡เดตเดธเตเดตเด‚ เดฌเต‹เตผเดกเตโ€Œ

เดญเต€เดฎเตป เดชเดพเดฑเด•เตเด•เดทเดฃเด™เตเด™เตพ เด…เดŸเตผเดจเตเดจเต เดฆเต‡เดถเต€เดฏ เดชเดพเดคเดฏเดฟเดฒเต‡เด•เตเด•เต เดตเต€เดดเตเดจเตเดจเดคเต เดชเดคเดฟเดตเดพเด•เตเดจเตเดจเต. เด•เตเดŸเตเดŸเดฟเด•เตเด•เดพเดจเดคเตเดคเดฟเดจเตเด‚ เดฎเตเดฃเตเดŸเด•เตเด•เดฏเดคเตเดคเดฟเดจเตเดฎเดฟเดŸเดฏเดฟเตฝ เดจเดฟเดฒเดจเดฟเตฝเด•เตเด•เตเดจเตเดจเดคเต เดตเตป เด…เดชเด•เดŸ เดญเต€เดทเดฃเดฟ

เดšเด•เตเดฐเดตเดพเดคเดšเตเดšเตเดดเดฟ:เด…เดคเดฟเดถเด•เตเดคเดฎเดพเดฏ เดฎเดด เดตเดฐเตเดจเตเดจเต

เดชเตเดฒเดธเต เดตเตบ เดชเตเดฐเดตเต‡เดถเดจเด‚. เด…เด•เตเดทเดฏเดฏเดฟเตฝ เดคเดฟเด•เตเด•เดฟ เดคเดฟเดฐเด•เตเด•เต‡เดฃเตเดŸ, เดจเต†เดฑเตเดฑเดฟเดตเดฟเดฑเตเดฑเดฟ/เดœเดพเดคเดฟ เดคเต†เดณเดฟเดฏเดฟเด•เตเด•เดพเตป เดชเดคเตเดคเดพเด‚เดคเดฐเด‚ เดธเตผเดŸเตเดŸเดฟเดซเดฟเด•เตเด•เดฑเตเดฑเต เดฎเดคเดฟ