Skip to content

elpezpr/puertoricoclock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Puerto Rico Digital Clock

A simple web application that displays the current time for Puerto Rico using data from the WorldTimeAPI.

Overview

Purpose: Provides users with the real-time clock of Puerto Rico, automatically fetching and updating the time every second.

Design: Uses the 'Roboto' font from Google Fonts and a clean, minimalist design with a centered layout. The clock is displayed in a modern, user-friendly interface with soft colors.

Functionality: Fetches the current time from the WorldTimeAPI for the 'America/Puerto_Rico' timezone and updates the clock every second using asynchronous JavaScript.

Test the App

You can test the clock directly on CodePen using the following link:
Live Demo

Technologies Used

  • HTML5
  • CSS3
  • JavaScript (ES6)
  • Google Fonts
  • WorldTimeAPI

Project Structure

  • index.html: Contains the HTML structure of the application.
  • styles.css: Includes all the styling for the clock and layout.
  • script.js: Handles fetching the current time, updating the DOM, and keeping the clock synchronized.

Notes

  • The project uses the WorldTimeAPI to fetch real-time data for the Puerto Rico timezone.
  • It updates the clock every second using JavaScript's setInterval method.
  • Error handling is implemented to display an error message if the time cannot be fetched.
  • The design is responsive, centering the content both vertically and horizontally.

Credits

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published