Skip to content

How to reset countdown #9

Description

@stasb

For anyone else wondering, if you want to automatically reset the countdown after it ends, setting a new targetDate prop is not enough. The trick is to set a new value as a key for the <Countdown /> component. I used my current epoch value as the key, which was held in state.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions