title: Initiate confetti effect (canvas) with JQuery
body: <p>I'd like to initiate this confetti effect when the user clicks with Jquery, but I'm not sure how, is there an easy way I could do this from an external js file with JQuery?</p>
  
  <p><a href="http://codepen.io/anon/pen/BpzxL" rel="nofollow">http://codepen.io/anon/pen/BpzxL</a></p>
  
  <p>N</p>
  
  <pre><code>UM_CONFETTI = 350
  COLORS = [[85,71,106], [174,61,99], [219,56,83], [244,92,68], [248,182,70]]
  PI_2 = 2*Math.PI
  
  
  canvas = document.getElementById "world"
  context = canvas.getContext "2d"
  window.w = 0
  window.h = 0
  
  resizeWindow = -&gt;
    window.w = canvas.width = window.innerWidth
    window.h = canvas.height = window.innerHeight
  </code></pre>
  
  <p>.....</p>
  
  <p>That's just a snippet of the code it's all in that codepen example.</p>