iso_calendar 0.0.4 icon indicating copy to clipboard operation
iso_calendar: ^0.0.4 copied to clipboard

Dart package to calculate year and week based on ISO-8601

iso_calendar #

Run flutter test

Dart package to calculate year and week based on ISO-8601

Getting Started #

Add a dependency in your pubspec.yaml:

dependencies:
  iso_calendar: ^0.0.4

Create an instance of IsoCalendar using .fromDateTime():

import 'package:iso_calendar/iso_calendar.dart';

void main() {
    final isoCalendar = IsoCalendar.fromDateTime(DateTime(2021, 1, 1))
    print(isoCalendar.year) // 2020
    print(isoCalendar.weekNumber) // 52
}
5
likes
90
pub points
72%
popularity

Publisher

shield icon for verified publishersiktakahiro.dev

Dart package to calculate year and week based on ISO-8601

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (LICENSE)

Dependencies

meta

More

Packages that depend on iso_calendar