|
|
||
|---|---|---|
| public | ||
| src | ||
| test | ||
| .gitignore | ||
| LICENSE | ||
| README.md | ||
| index.html | ||
| package-lock.json | ||
| package.json | ||
README.md
YouTube API Interface
A simple app for interacting with the YouTube API.
Description
This project provides a basic interface for searching and displaying YouTube videos. It uses the YouTube API to fetch video data and displays the results in a grid.
Tools used
- vite with the vanilla js template
- lit
Features
- Search for videos by keyword
- Sort search results by relevance, date, or rating
- Display video thumbnails, titles, and descriptions
- Link to YouTube video pages
- Pagination for large result sets
Dependencies
This project uses the following dependencies:
axiosfor making API requestsdotenvfor environment variable managementlitfor building the UI componenttwindfor styling
Setup
- Clone the repository:
git clone https://gitea.jeremyhayes.me/Cybernomad/youtube-api.git - Install dependencies:
npm installor if you prefernpm i - Create a
.envfile with your YouTube API key:API_KEY=YOUR_API_KEY_HERE - Start the development server:
npm run dev
Usage
- Open the app in your browser:
http://localhost:5173 - Enter a search keyword in the input field
- Select a sort option from the dropdown menu
- Click the "Search" button to fetch video data
- Browse the search results and click on a video to open its YouTube page
License
This project is licensed under the MIT License. See the LICENSE file for details.