title: replace multiple consecutive hyphens with one
body: <p>Is this possible in Javascript?</p>
  
  <p>I have this from Java, but can not be used in Javascript.</p>
  
  <pre><code>s/-{2,}/-/g
  </code></pre>
  
  <p>Is there another way that works?</p>