Skip to content

A Flutter package that provides a widget to listen to the system's datetime and trigger a rebuild based on the specified time unit.

License

Notifications You must be signed in to change notification settings

gnassro/datetime_loop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

datetime_loop

A Flutter package that provides a widget to listen to the system's datetime and trigger a rebuild based on the specified time unit.

Usage

Import the package in your Dart code:

import 'package:datetime_loop/datetime_loop.dart';

Use the DateTimeLoopBuilder widget in your Flutter app:

DateTimeLoopBuilder(
  timeUnit: TimeUnit.seconds,
  builder: (context, dateTime, child) {
    return Column(
      children: [
        Container(
          width: 200,
          height: 200,
          color: Color((math.Random().nextDouble() * 0xFFFFFF).toInt()).withOpacity(1.0),
        ),
        Text('$dateTime'),
      ],
    );
  }
)

Issues and Feedback

Please file any issues or feedback here.

About

A Flutter package that provides a widget to listen to the system's datetime and trigger a rebuild based on the specified time unit.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published