lunar_calendar_converter 1.0.3 copy "lunar_calendar_converter: ^1.0.3" to clipboard
lunar_calendar_converter: ^1.0.3 copied to clipboard

outdated

This package contains a converter to convert calendar from one to another between lunar calendar and solar calendar, it can also convert a date to Chinese text with Tiangan and Dizhi. For more details [...]

example/main.dart

import './../lib/lunar_solar_converter.dart';

main(List<String> arguments) {
  Lunar lunar = Lunar(lunarYear: 2020, lunarMonth: 4, lunarDay: 4, isLeap: true);
  var result1 = LunarSolarConverter.lunarToSolar(lunar);
  var dateTime = result1.dateTime;
  print("$lunar -> $result1 / $dateTime");

  Solar solar = Solar(solarYear: 2020, solarMonth: 5, solarDay: 26);
  Lunar result2 = LunarSolarConverter.solarToLunar(solar);
  print("$solar -> $result2");
}
10
likes
0
pub points
43%
popularity

Publisher

unverified uploader

This package contains a converter to convert calendar from one to another between lunar calendar and solar calendar, it can also convert a date to Chinese text with Tiangan and Dizhi. For more details, Please read README.md.

Repository (GitHub)
View/report issues

License

unknown (license)

More

Packages that depend on lunar_calendar_converter