title: I want to truncate a text or line with ellipsis using JavaScript
body: <p>I'm looking for a simple script which can truncate a string with ellipsis (...)</p>
  
  <p>I want to truncate something like <code>'this is a very long string'</code> to <code>'this is a ve...'</code></p>
  
  <p>I don't want to use CSS or PHP.</p>