<script type='text/template' id='line-item-template'>
  <td class="cart-item-image" data-hook="cart_item_image">
    <a href='#'>
      <img alt="<%%= variant.name %>" src="<%%= displayImage('small') %>" data-product-permalink='<%%= permalink() %>'>
    </a>
  </td>
  <td class="cart-item-description" data-hook="cart_item_description">
    <h4><a href='#' data-product-permalink='<%%= permalink() %>'><%%= variant.name %></a></h4>
    <%%= variant.description %>
  </td>
  <td class="cart-item-price" data-hook="cart_item_price">
    <%%= single_display_amount %>
  </td>
  <td class="cart-item-quantity" data-hook="cart_item_quantity">
    <input class="line_item_quantity" data-line-item-id='<%%= id %>' size="5" type="number" value="<%%= quantity %>" min='0'>
  </td>
  <td class="cart-item-total" data-hook="cart_item_total">
    <%%= display_amount %>
  </td>
  <td class="cart-item-delete" data-hook="cart_item_delete">
    <a href="#" class="delete" id="delete_line_item_4"><img alt="Delete" src="/assets/icons/delete.png"></a>
  </td>
</script>
<script type='text/template' id='line-item-template'>
  <td class="cart-item-image" data-hook="cart_item_image">
    <a href='#'>
      <img alt="<%%= variant.name %>" src="<%%= displayImage('small') %>" data-product-permalink='<%%= permalink() %>'>
    </a>
  </td>
  <td class="cart-item-description" data-hook="cart_item_description">
    <h4><a href='#' data-product-permalink='<%%= permalink() %>'><%%= variant.name %></a></h4>
    <%% if (variant.description.length > 50) { %>      
      <%%= variant.description.substring(0, 50) %>...
    <%% } else { %>
      <%%= variant.description %>
    <%% } %>
  </td>
  <td class="cart-item-price" data-hook="cart_item_price">
    <%%= single_display_amount %>
  </td>
  <td class="cart-item-quantity" data-hook="cart_item_quantity">
    <input class="line_item_quantity" data-line-item-id='<%%= id %>' size="5" type="number" value="<%%= quantity %>" min='0'>
  </td>
  <td class="cart-item-total" data-hook="cart_item_total">
    <%%= display_amount %>
  </td>
  <td class="cart-item-delete" data-hook="cart_item_delete">
    <a href="#" class="delete" id="delete_line_item_4"><img alt="Delete" src="/assets/icons/delete.png"></a>
  </td>
</script>
Truncate variant descriptions in cart
Truncate variant descriptions in cart
