virtual_clock 1.0.0-dev.1 copy "virtual_clock: ^1.0.0-dev.1" to clipboard
virtual_clock: ^1.0.0-dev.1 copied to clipboard

A Flutter package for virtual time manipulation and acceleration. Perfect for testing time-based features like streaks, daily bonuses, and scheduled events without waiting in real-time.

Changelog #

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

1.0.0-dev.1 - 2026-01-06 #

Added #

  • Initial release of Virtual Clock package
  • ClockService - Core service for virtual time management
    • Time acceleration with configurable clock rate
    • Time travel to any date/time
    • Fast forward by duration
    • Pause and resume functionality
    • Persistence across app restarts
    • Auto-reset on app version changes
    • Production safety (forced to 1x in release builds)
  • VirtualClock - Global accessor for convenient clock access
  • VirtualTimer - Timer wrappers that respect virtual time
    • periodic() - Repeating timer
    • delayed() - One-time timer
    • wait() - Async wait
  • VirtualClockX - DateTime extensions
    • isVirtualToday() - Check if date is today in virtual time
    • isVirtualYesterday() - Check if date is yesterday in virtual time
    • isInVirtualPast() - Check if date is in virtual past
    • isInVirtualFuture() - Check if date is in virtual future
    • differenceFromVirtualNow() - Get difference from virtual now
    • isDifferentFromVirtualNow() - Check if different from virtual now
  • ClockConfig - Configuration class for clock initialization
  • Comprehensive documentation and examples
0
likes
0
points
160
downloads

Publisher

verified publisherdjoks.dev

Weekly Downloads

A Flutter package for virtual time manipulation and acceleration. Perfect for testing time-based features like streaks, daily bonuses, and scheduled events without waiting in real-time.

Repository (GitHub)
View/report issues

Topics

#time #testing #virtual-time #clock #debugging

License

unknown (license)

Dependencies

flutter, intl, shared_preferences

More

Packages that depend on virtual_clock