8469982378 | ||
---|---|---|
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:
axios
for making API requestsdotenv
for environment variable managementlit
for building the UI componenttwind
for styling
Setup
- Clone the repository:
git clone https://gitea.jeremyhayes.me/Cybernomad/youtube-api.git
- Install dependencies:
npm install
or if you prefernpm i
- Create a
.env
file 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.