title: Create a href link that uses http DELETE verb in express.js
body: <p>I just started playing with express.js using handlebars.js as my template
  I wanted to create a delete link, which should be restful and use http verb DELETE 
  instead of GET.</p>
  
  <p>I finally figured out a way to achieve it by creating a link like so below,
  adding data-method of delete, and then using jquery on client side to intercept
  my link to use DELETE verb.</p>
  
  <p>My link was:</p>
  
  <pre><code>&lt;a href="/destroy/{{_id}}" data-method="delete"&gt;delete&lt;/a&gt;
  
  &lt;script src="http://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"&gt;&lt;/script&gt;
  &lt;script&gt;
  $("a[data-method='delete']").click(function(){
      $.ajax({
          url: this.getAttribute('href'),
          type: 'DELETE'
      })
      return false
  })
  &lt;/script&gt;
  </code></pre>
  
  <p>Is this a recommendable way of achieving this in express.js/handlebars.js?, does anyone have a better way of achieving this?, I haven't been able to find something similar to how rails does it within its helper like:</p>
  
  <pre><code>link_to("Destroy", "http://www.example.com", method: :delete)
  </code></pre>