JSFiddle - React, Tailwind, and code Playground

by ddcast

HTML

<script src="https://s3.amazonaws.com/githubstatic/text-countdown-1.0.1-en-us.min.js"></script>
<div class="countdown-timer"
  data-month="8"
  data-day="4"
  data-year="2015"
  data-hour="17"
  data-prefix="The soup sale starts in "
  data-suffix=". Hooray!"
  data-delimiter=" and"
>No soup for you!</div>

CSS

body {
    font-family: "Trebuchet MS" Arial;
}

JavaScript

// Manually updating values here to make sure this example works over time
var now = new Date();
$('.countdown-timer').textCountdown({
    month: now.getMonth() + 1,
    day: now.getDate() + 7,
    year: now.getFullYear()
});