/PerfectTime

An overengineered analog clock designed to show the perfect time every time.

Primary LanguageJavaScriptMIT LicenseMIT

LinkedIn


Logo

PerfectTime

An overengineered analog clock designed to show the perfect time every time.
https://PerfectTime.org

Table of Contents
  1. About The Project
  2. Getting Started
  3. Configuration
  4. Contributing
  5. License
  6. Contact
  7. Acknowledgments

About The Project

PerfectTime Screen Shot

PerfectTime is a highly accurate, highly configurable analog clock built using modern web technologies. The clock is rendered with Three.js and designed to synchronize with the NTP pool, ensuring it displays the most accurate time possible across all devices.

Key features:

  • Full compatibility with Android and iOS using Ionic's Capacitor.
  • 3D analog clock rendered using Three.js.
  • Synchronization with NTP for accurate timekeeping.
  • Dynamic design that scales to fit the device.
  • Light and dark color schemes.
  • Support for 19 different languages.
  • Customizable display options for a personalized experience.

(back to top)

Built With

  • Three.js
  • Node.js
  • Bootstrap
  • Capacitor

Getting Started

To get a local copy up and running, follow these simple steps.

Prerequisites

  • Node.js
    • This was developed with Node.js v20.11.0. Other versions may also work but have not been thoroughly tested.

Installation

  1. Clone the repo
    git clone https://github.com/dylanmounts/PerfectTime.git
  2. Navigate to the repo directory
    cd PerfectTime
  3. Install NPM packages
    npm install
  4. Build the app
    npm run build
  5. Start the app
    npm start
  6. Access the app in your web browser.
    1. By default, it will be available at http://127.0.0.1:8100.
    2. This can be changed by setting the PERFECT_PORT and PERFECT_HOSTNAME environment variables.

(back to top)

Configuration

PerfectTime can be configured using environment variables to suit different deployment environments. Below are the environment variables supported:

  • PERFECT_PORT: Specifies the port on which the app runs. If not set, the app defaults to port 8100.
  • PERFECT_HOSTNAME: Determines the hostname for the app. Default is 127.0.0.1 when not specified.
  • PERFECT_WEB_APP: A boolean (true or false) indicating if the application is running as a web app (desktop browser) or a mobile app (Android or iOS). This affects display and styling configurations unique to mobile devices. Defaults to false.

Additionally, the backend time server will only run if PERFECT_WEB_APP is set to true, since mobile versions rely on the web app's time server to retrieve their perfect time.

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

Contact

Dylan Mounts - dmounts@gmail.com

Project Link: https://github.com/dylanmounts/PerfectTime

(back to top)

Acknowledgments

(back to top)