Using Readmore JS correctly

<script src="js/readmore.min.js"></script>
<script>
  $('.manage2').readmore({
    maxHeight: 100
  });
 
  // Wait a tick before firing Readmore on the #info block to give Prettify time to finish painting.
  setTimeout(function() {
    $('.manage2').readmore({
      moreLink: '<a href="#" style="color:#4a89dc">Read More</a>',

lessLink: '<a href="#" class="managename" style="color:#4a89dc">Close</a>',
      maxHeight: 100,
      afterToggle: function(trigger, element, more) {
        if(! more) { // The "Close" link was clicked
          $('html, body').animate( { scrollTop: element.offset().top }, {duration: 100 } );
        }
      }
    });
  }, 100);
</script>
<!---Read more codeEND-->