https://github.com/andreewille/time-span
a dart library that calculates the time span in hours or minutes for two given time strings of format HH:SS
https://github.com/andreewille/time-span
dart dartlang duration library string time time-calculator time-spans
Last synced: over 1 year ago
JSON representation
a dart library that calculates the time span in hours or minutes for two given time strings of format HH:SS
- Host: GitHub
- URL: https://github.com/andreewille/time-span
- Owner: AndreeWille
- License: bsd-3-clause
- Created: 2020-01-17T12:42:33.000Z (over 6 years ago)
- Default Branch: main
- Last Pushed: 2021-05-27T08:49:58.000Z (about 5 years ago)
- Last Synced: 2025-04-04T03:17:59.000Z (over 1 year ago)
- Topics: dart, dartlang, duration, library, string, time, time-calculator, time-spans
- Language: Dart
- Homepage:
- Size: 13.7 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
A Dart library that parses two time strings of format HH:MM and calculates the time span in minutes as int or hours as double.
## Usage
A simple usage example:
```dart
import 'package:time_span/time_span.dart';
void main() {
var timeSpan = TimeSpan('09:00', '21:30');
print('Time span in hours: ${timeSpan.inHours}'); // 12.5
print('Time span in inMinutes: ${timeSpan.inMinutes}'); // 750
}
```
## Features and bugs
Please file feature requests and bugs at the [issue tracker][tracker].
[tracker]: https://github.com/AndreeWille/time-span/issues