[LRUG] Best practices for javascript in Rails apps

Alexander Hockey-Sweeney alexsween at gmail.com
Thu Jul 18 06:14:50 PDT 2013


On a related note to javascript within Rails apps - does anyone have any
tips for reporting javascript errors (with a Rails app)? Something similar
to the rails exception_notification gem, but for javascript.

Google digging yielded a few solutions (below), but wondering if anyone has
come across other solutions.

Cheers,
Alex


http://devblog.pipelinedeals.com/pipelinedeals-dev-blog/2012/2/12/javascript-error-reporting-for-fun-and-profit-1.html
http://jslogger.com/








On Thu, Jul 18, 2013 at 1:56 PM, David Salgado <david at digitalronin.com>wrote:

>
> On 18 July 2013 13:10, Frederick Cheung <frederick.cheung at gmail.com>wrote:
>
>> 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.
>
>
> I use gon for that;
>
> https://github.com/gazay/gon
>
> Also mentioned here;
>
> http://railscasts.com/episodes/324-passing-data-to-javascript
>
> It's doing the same thing under the hood, but it's a nice encapsulation.
>
> David
>
>
>
>
> _______________________________________________
> Chat mailing list
> Chat at lists.lrug.org
> http://lists.lrug.org/listinfo.cgi/chat-lrug.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lrug.org/pipermail/chat-lrug.org/attachments/20130718/f15b373a/attachment-0003.html>


More information about the Chat mailing list