JSFiddle - React, Tailwind, and code Playground

by Shree Khanal

HTML

<div class="main">
  <div class="title">
    <p>This title text should be changed</p>
    </div>
  <div class="description">
    <p>This description should als be changed</p>
    </div>
 </div>

CSS

.main{
background-color: orange;
color: white;
}

JavaScript

$('.main .title').data("timeout", setTimeout(function () {
      $('.main .title').text("Changed title!");
    }, 2000));
    $('.main .description').data("timeout", setTimeout(function () {
   $('.main .description').text("Changed Description");
    }, 4000));