Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/priyanshjain9414/quote-generator
A simple web application that fetches random quotes from various categories and allows users to save their favorite quotes.
https://github.com/priyanshjain9414/quote-generator
api api-ninja css html html-css-javascript javascript
Last synced: 14 days ago
JSON representation
A simple web application that fetches random quotes from various categories and allows users to save their favorite quotes.
- Host: GitHub
- URL: https://github.com/priyanshjain9414/quote-generator
- Owner: priyanshjain9414
- Created: 2024-11-03T07:17:38.000Z (2 months ago)
- Default Branch: main
- Last Pushed: 2024-11-03T07:23:37.000Z (2 months ago)
- Last Synced: 2024-11-10T12:49:31.594Z (about 2 months ago)
- Topics: api, api-ninja, css, html, html-css-javascript, javascript
- Language: JavaScript
- Homepage:
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Random Quote Generator
## Description
The Random Quote Generator is a simple web application that fetches random quotes from the **API Ninja** and displays them to the user. Users can choose from various categories to get quotes that inspire, motivate, or entertain. This project aims to provide a fun and interactive way to discover new quotes.
## Features
- Fetch random quotes based on selected categories.
- Display the quote text and author.
- Button to generate a new quote.
- Save favorite quotes with a simple alert feature.## Technologies Used
- HTML
- CSS
- JavaScript
- API Ninja (for fetching quotes)## Installation
1. Clone the repository:
```bash
git clone https://github.com/yourusername/random-quote-generator.git
```
2. Navigate to the project directory:
```bash
cd random-quote-generator
```
3. Open index.html in your preferred web browser.## Usage
1. **Select a Category:** Choose a category from the dropdown menu.
2. **Get a Quote:** Click the "Get a Quote" button to fetch a random quote from the selected category. The quote and its author will be displayed on the screen.
3. **Save Favorite:** Click the "Save Favorite" button to save your favorite quote (for demonstration, this will display an alert).## API Key
To use the API Ninja for fetching quotes, you will need to sign up and obtain an API key. Replace the placeholder `YOUR_API_KEY` in `script.js` with your actual API key.
## Contributing
Contributions are welcome! If you have suggestions or improvements, please open an issue or submit a pull request.