JSFiddle - React, Tailwind, and code Playground

by Kunal Virk

HTML

<div class="paraHolder">
  <p>Here we make the text scroll from right to left.</p>
  <p>You can slow down the marquee by using a higher number, or speed it up using a lower number. Let's slow it down by changing the value.</p>
  <p>Yes, Instamojo does provide you with an option to create a sandbox account to test your integration before you can go live on your website or application. You can test various scenarios and use a dummy card for test transactions. We have mentioned the steps to create a test account below</p>
</div>

CSS

p { font-family:'Arial', sans-serif; transition:all 0.2s ease-in-out;}

JavaScript

$(window).on("load", function() {
  var getLines = $('.paraHolder p');
	console.log(getLines)
  getLines.each(function(i, el) {
    var lineHeight = $(el).height();
    $(el).css({
      'transform' : 'translateY(-'+ lineHeight +')'
    });
  });
})