<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On 18 July 2013 13:10, Frederick Cheung <span dir="ltr"><<a href="mailto:frederick.cheung@gmail.com" target="_blank">frederick.cheung@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">There's still a slightly awkward feeling when I want to pass a larger chunk of data to the javascript. I normally end up with a inline javascript snippet setting window.foo but I've never felt very happy about that.</blockquote>
</div><div class="gmail_extra"><br></div>I use gon for that;</div><div class="gmail_extra"><br></div><div class="gmail_extra"><a href="https://github.com/gazay/gon">https://github.com/gazay/gon</a><br></div><div class="gmail_extra">
<br></div><div class="gmail_extra">Also mentioned here;</div><div class="gmail_extra"><br></div><div class="gmail_extra"><a href="http://railscasts.com/episodes/324-passing-data-to-javascript">http://railscasts.com/episodes/324-passing-data-to-javascript</a></div>
<div class="gmail_extra"><br></div><div class="gmail_extra">It's doing the same thing under the hood, but it's a nice encapsulation.</div><div class="gmail_extra"><br></div><div class="gmail_extra">David</div><div class="gmail_extra">
<br></div><div class="gmail_extra"><br><br></div></div>