JSFiddle - React, Tailwind, and code Playground

by eorozco

HTML

<div class="view-content">
      <table id="datatable-1" class="views-table cols-14 display"
	>
    <thead>
		<tr>
              <th
				class="views-field views-field-nombre">
          Nombre del curso        </th>
              <th
				class="views-field views-field-clave-1">
          Clave del curso        </th>
              <th
				class="views-field views-field-clave">
          Clave del Grupo        </th>
              <th
				class="views-field views-field-cupo">
          Cupo        </th>
              <th
				class="views-field views-field-fecha-ini-pub">
          Fecha ini pub        </th>
              <th
				class="views-field views-field-fecha-fin-pub">
          Fecha fin pub        </th>
              <th
				class="views-field views-field-fecha-ini">
          Fecha ini        </th>
              <th
				class="views-field views-field-fecha-fin">
          Fecha fin        </th>
              <th
				class="views-field views-field-creado">
          Creado        </th>
              <th
				class="views-field views-field-modificado">
          Modificado        </th>
              <th
				class="views-field views-field-tipo">
          Tipo        </th>
              <th
				class="views-field views-field-php">
          Activo        </th>
              <th
				class="views-field views-field-eid">
          Modificar        </th>
              <th
				class="views-field views-field-php-1">
          Inscripciones        </th>
          </tr>
	</thead>
	<tbody>
          <tr class="">
                  <td
				class="views-field views-field-nombre">
            Pop Corn          </td>
                  <td
				class="views-field views-field-clave-1">
            CINE101          </td>
                  <td
				class="views-field views-field-clave">
            CINE101-001          </td>
                  <td
				class="views-field views-field-cupo">
            5          </td>
                  <td
				class="views-field...

JavaScript

/**
 * Timeago is a jQuery plugin that makes it easy to support automatically
 * updating fuzzy timestamps (e.g. "4 minutes ago" or "about 1 day ago").
 *
 * @name timeago
 * @version 1.4.0
 * @requires jQuery v1.2.3+
 * @author Ryan McGeary
 * @license MIT License - http://www.opensource.org/licenses/mit-license.php
 *
 * For usage and examples, visit:
 * http://timeago.yarp.com/
 *
 * Copyright (c) 2008-2013, Ryan McGeary (ryan -[at]- mcgeary [*dot*] org)
 */

(function (factory) {
  if (typeof define === 'function' && define.amd) {
    // AMD. Register as an anonymous module.
    define(['jquery'], factory);
  } else {
    // Browser globals
    factory(jQuery);
  }
}(function ($) {
  $.timeago = function(timestamp) {
    if (timestamp instanceof Date) {
      return inWords(timestamp);
    } else if (typeof timestamp === "string") {
      return inWords($.timeago.parse(timestamp));
    } else if (typeof timestamp === "number") {
      return inWords(new Date(timestamp));
    } else {
      return inWords($.timeago.datetime(timestamp));
    }
  };
  var $t = $.timeago;

  $.extend($.timeago, {
    settings: {
      refreshMillis: 60000,
      allowPast: true,
      allowFuture: false,
      localeTitle: false,
      cutoff: 0,
      strings: {
        prefixAgo: null,
        prefixFromNow: null,
        suffixAgo: "ago",
        suffixFromNow: "from now",
        inPast: 'any moment now',
        seconds: "less than a minute",
        minute: "about a minute",
        minutes: "%d minutes",
        hour: "about an hour",
        hours: "about %d hours",
        day: "a day",
        days: "%d days",
        month: "about a month",
        months: "%d months",
        year: "about a year",
        years: "%d years",
        wordSeparator: " ",
        numbers: []
      }
    },

    inWords: function(distanceMillis) {
      if(!this.settings.allowPast && ! this.settings.allowFuture) {
          throw 'timeago allowPast and allowFuture settings can not both be...