Description
Time is a Swift package for date and time calculations that are robust and type-safe. The project explains that calendar work is complicated and error-prone, and it addresses this by clarifying the concepts and restricting improper use through the API. system, which tells you the current time: a day value for today's date, or a minute value for the current time. Each of those values has methods to get more or less precise units, so you can list the hours in a day, for example. Values can be formatted into readable strings. 7 or later and macOS 13, iOS 16 or equivalent, because it builds on the Duration type introduced in those releases. Installation is through Swift Package Manager. The extensive documentation is hosted on the Swift Package Index, and the repository contains an Examples folder. The project is fully open source on GitHub, and issues and feature requests are welcome there.…
Highlights
- Type-safe date and time calculations
- RegionalClock for current time
- Formatting and precision methods
- Built on Swift Duration
- Swift Package Manager installation
Ratings & Reviews
No ratings yet
Be the first to rate Time.
People also visit
Time FAQ
What is Time?
A Swift package for robust, type-safe date and time calculations.
How do I install it?
Add it to the dependencies in your Package.swift file, as the README shows.
What does it require?
Swift 5.7 or later, and macOS 13 or iOS 16 or equivalent.
Where is the documentation?
On the Swift Package Index, with an Examples folder in the repository.
What are the best Time alternatives?
Popular alternatives to Time include Datez, Fastis and Calendr. See all Time alternatives

