seconds_countdown_timer 0.0.5 copy "seconds_countdown_timer: ^0.0.5" to clipboard
seconds_countdown_timer: ^0.0.5 copied to clipboard

retractedoutdated

package that provide countdown timer with customized widget.

Provide countdown timer with customizable widget

Features #

Create a countdown timer based on the end time (in seconds) and the start date (DateTime) of the timer. This package does not use DateTime.now, as it may be affected when the platform's date and time are changed by the user.

Installation #

Add the following line to your pubspec.yaml file:

dependencies:
  seconds_countdown_timer: <latest_version>

Usage #

import 'package:seconds_countdown_timer/seconds_countdown_timer.dart';

class MyWidget extends StatelessWidget {
  Widget build(BuildContext context) {
    return Center(
      child: SecondsCountdownTimer(
        endTime: 60,
        startDate: DateTime.now(),
        widgetBuilder: (_, time) {
          return Text("${time?.hours ?? 0} : ${time?.min ?? 0} : ${time?.sec ?? 0}");
        },
      ),
    );
  }
}
5
likes
0
points
81
downloads

Publisher

unverified uploader

Weekly Downloads

package that provide countdown timer with customized widget.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on seconds_countdown_timer