simple_durations 1.0.5
simple_durations: ^1.0.5 copied to clipboard
Extensions on int to easily create Durations directly from ints. Can be used for units as small as planck time all the way up to galactic years and beyond.
Use this package as a library
Depend on it
Run this command:
With Dart:
$ dart pub add simple_durationsThis will add a line like this to your package's pubspec.yaml (and run an implicit dart pub get):
dependencies:
simple_durations: ^1.0.5Alternatively, your editor might support dart pub get. Check the docs for your editor to learn more.
Import it
Now in your Dart code, you can use:
import 'package:simple_durations/simple_durations.dart';