<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Unobtrusive JavaScript in Rails 3</title>
	<atom:link href="http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/</link>
	<description>Simone Carletti&#039;s personal ramblings on programming, syndication, search engines &#38; marketing.</description>
	<lastBuildDate>Thu, 09 Feb 2012 14:24:07 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Marlin Pierce</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40597</link>
		<dc:creator>Marlin Pierce</dc:creator>
		<pubDate>Wed, 01 Feb 2012 13:13:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40597</guid>
		<description>Let me be clear up front that this was a great article; it was very helpful; it was in fact the definitive statement which convinced us that we needed to exclude prototype and Rails prototype helpers in our non-legacy development.

However, I did not find the justification for Rails switching from prototype to jQuery convincing.  The observer example was not less verbose.  I don&#039;t see an advantage of Rails being no longer prototype oriented.  I don&#039;t consider using jQuery to be framework agnostic, as it depends on the jQuery framework.

Maybe I am missing that, unlike the prototype support, Rails is decoupled from jQuery, as it does not have jQuery dependent helpers.  Maybe that&#039;s it.  I was not happy when I first learned Rails that it was prototype dependent.  However, once using it, taking it away is a decision I disagree with.

I also disagree that it&#039;s a positive that the jQuery way, forces developers to have a deeper JavaScript knowledge than in the past.  There are a number of systems to gloss over JavaScript, gwt, extJS, and jQuery.  JavaScript is a little clunky, and the DOM api is definitely clunky.

My hope would be that a JS gloss framework became so popular that it was incorporated natively in browsers.  For instance, observers could be added to the JavaScript foundation.  Rails selection of prototype, brings prototype almost to a justifiable standard as a candidate for such inclusion.  Abandoning prototype, and switching frameworks undermines this hope.</description>
		<content:encoded><![CDATA[<p>Let me be clear up front that this was a great article; it was very helpful; it was in fact the definitive statement which convinced us that we needed to exclude prototype and Rails prototype helpers in our non-legacy development.</p>
<p>However, I did not find the justification for Rails switching from prototype to jQuery convincing.  The observer example was not less verbose.  I don&#8217;t see an advantage of Rails being no longer prototype oriented.  I don&#8217;t consider using jQuery to be framework agnostic, as it depends on the jQuery framework.</p>
<p>Maybe I am missing that, unlike the prototype support, Rails is decoupled from jQuery, as it does not have jQuery dependent helpers.  Maybe that&#8217;s it.  I was not happy when I first learned Rails that it was prototype dependent.  However, once using it, taking it away is a decision I disagree with.</p>
<p>I also disagree that it&#8217;s a positive that the jQuery way, forces developers to have a deeper JavaScript knowledge than in the past.  There are a number of systems to gloss over JavaScript, gwt, extJS, and jQuery.  JavaScript is a little clunky, and the DOM api is definitely clunky.</p>
<p>My hope would be that a JS gloss framework became so popular that it was incorporated natively in browsers.  For instance, observers could be added to the JavaScript foundation.  Rails selection of prototype, brings prototype almost to a justifiable standard as a candidate for such inclusion.  Abandoning prototype, and switching frameworks undermines this hope.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dan Garland</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40579</link>
		<dc:creator>Dan Garland</dc:creator>
		<pubDate>Tue, 10 Jan 2012 15:34:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40579</guid>
		<description>&quot;Placing a javascript_tag in the middle of a page is probably not so unobtrusive&quot;

It defeats the purpose as far as I can tell.</description>
		<content:encoded><![CDATA[<p>&#8220;Placing a javascript_tag in the middle of a page is probably not so unobtrusive&#8221;</p>
<p>It defeats the purpose as far as I can tell.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel X. Moore</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40578</link>
		<dc:creator>Daniel X. Moore</dc:creator>
		<pubDate>Tue, 10 Jan 2012 01:56:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40578</guid>
		<description>I think that &#039;ajax:failure&#039; has been replaced with &#039;ajax:error&#039;. See source here: https://github.com/rails/jquery-ujs/blob/82292010fb1743f038ab72b1f1e994e91be3eda3/src/rails.js#L148</description>
		<content:encoded><![CDATA[<p>I think that &#8216;ajax:failure&#8217; has been replaced with &#8216;ajax:error&#8217;. See source here: <a href="https://github.com/rails/jquery-ujs/blob/82292010fb1743f038ab72b1f1e994e91be3eda3/src/rails.js#L148" rel="nofollow">https://github.com/rails/jquery-ujs/blob/82292010fb1743f038ab72b1f1e994e91be3eda3/src/rails.js#L148</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tiago Sarri</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40574</link>
		<dc:creator>Tiago Sarri</dc:creator>
		<pubDate>Tue, 03 Jan 2012 20:31:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40574</guid>
		<description>Thanks for helping me, the ajax:failure event note if user cancel the xhr</description>
		<content:encoded><![CDATA[<p>Thanks for helping me, the ajax:failure event note if user cancel the xhr</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gordon</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40571</link>
		<dc:creator>Gordon</dc:creator>
		<pubDate>Sun, 01 Jan 2012 04:41:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40571</guid>
		<description>hi there, 
 thank you for this tutorial.
I&#039;m reimplementing an existing rails 2.3.8 app with rails 3.1.x

As I follow this tutorial, it seems that my _path helper url value doesn&#039;t get interpolated in the javascript.

For example, in your tutorial,
1
2
3
4
5
6
7
8
9
10
// Append the function to the &quot;document ready&quot; chain
jQuery(function($) {
  // when the #search field changes
  $(&quot;#search&quot;).change(function() {
    // make a POST call and replace the content
    $.post(, function(data) {
      $(&quot;#results&quot;).html(data);
    });
  });
})

the live_search_path does not get translated into an actual path.

Please help.</description>
		<content:encoded><![CDATA[<p>hi there,<br />
 thank you for this tutorial.<br />
I&#8217;m reimplementing an existing rails 2.3.8 app with rails 3.1.x</p>
<p>As I follow this tutorial, it seems that my _path helper url value doesn&#8217;t get interpolated in the javascript.</p>
<p>For example, in your tutorial,<br />
1<br />
2<br />
3<br />
4<br />
5<br />
6<br />
7<br />
8<br />
9<br />
10<br />
// Append the function to the &#8220;document ready&#8221; chain<br />
jQuery(function($) {<br />
  // when the #search field changes<br />
  $(&#8220;#search&#8221;).change(function() {<br />
    // make a POST call and replace the content<br />
    $.post(, function(data) {<br />
      $(&#8220;#results&#8221;).html(data);<br />
    });<br />
  });<br />
})</p>
<p>the live_search_path does not get translated into an actual path.</p>
<p>Please help.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Keith</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40470</link>
		<dc:creator>Keith</dc:creator>
		<pubDate>Tue, 29 Nov 2011 20:26:44 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40470</guid>
		<description>Thanks for helping me better understand unobtrusive javascript in rails 3.

There&#039;s a grammatical mistake I found in the &quot;So What?&quot; section. You have &quot;what does this means&quot;, but it should be &quot;what does this mean&quot;. Any time you have something like &quot;do&quot;, &quot;does&quot;, or &quot;will&quot;, etc. in front of the verb, you would use &quot;mean&quot; instead of &quot;means&quot;. &quot;This means...&quot; vs. &quot;What does this mean?&quot; or &quot;This does mean...&quot;. Hope that helps.</description>
		<content:encoded><![CDATA[<p>Thanks for helping me better understand unobtrusive javascript in rails 3.</p>
<p>There&#8217;s a grammatical mistake I found in the &#8220;So What?&#8221; section. You have &#8220;what does this means&#8221;, but it should be &#8220;what does this mean&#8221;. Any time you have something like &#8220;do&#8221;, &#8220;does&#8221;, or &#8220;will&#8221;, etc. in front of the verb, you would use &#8220;mean&#8221; instead of &#8220;means&#8221;. &#8220;This means&#8230;&#8221; vs. &#8220;What does this mean?&#8221; or &#8220;This does mean&#8230;&#8221;. Hope that helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Simone Carletti</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40468</link>
		<dc:creator>Simone Carletti</dc:creator>
		<pubDate>Mon, 28 Nov 2011 13:59:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40468</guid>
		<description>I&#039;m sorry, but I don&#039;t have any link handy. However, there are plenty of tutorials available online.
Just make sure to discard outdated posts.</description>
		<content:encoded><![CDATA[<p>I&#8217;m sorry, but I don&#8217;t have any link handy. However, there are plenty of tutorials available online.<br />
Just make sure to discard outdated posts.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe McGouran</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-40467</link>
		<dc:creator>Joe McGouran</dc:creator>
		<pubDate>Mon, 28 Nov 2011 13:45:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-40467</guid>
		<description>Simone - very interesting article.

I have acollege project to integrate into / enhance a Rails 3 scaffold app with Ajax, JQuery, dynamic DOM update,CSS, etc.. Do you know of any other papers that describe how to go about this.

Look forward to your response.</description>
		<content:encoded><![CDATA[<p>Simone &#8211; very interesting article.</p>
<p>I have acollege project to integrate into / enhance a Rails 3 scaffold app with Ajax, JQuery, dynamic DOM update,CSS, etc.. Do you know of any other papers that describe how to go about this.</p>
<p>Look forward to your response.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Simone Carletti</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-38859</link>
		<dc:creator>Simone Carletti</dc:creator>
		<pubDate>Thu, 22 Sep 2011 09:15:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-38859</guid>
		<description>I&#039;m sure the order is correct. Make sure you are adding the event parameter as well.

&lt;pre&gt;(event, xhr, status, error)&lt;/pre&gt;</description>
		<content:encoded><![CDATA[<p>I&#8217;m sure the order is correct. Make sure you are adding the event parameter as well.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">(event, xhr, status, error)</div></td></tr></tbody></table></div>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike Bailey</title>
		<link>http://www.simonecarletti.com/blog/2010/06/unobtrusive-javascript-in-rails-3/#comment-38856</link>
		<dc:creator>Mike Bailey</dc:creator>
		<pubDate>Thu, 22 Sep 2011 08:38:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.simonecarletti.com/blog/?p=1105#comment-38856</guid>
		<description>This post has withstood the test of time. That&#039;s for laying things out so clearly Simone!</description>
		<content:encoded><![CDATA[<p>This post has withstood the test of time. That&#8217;s for laying things out so clearly Simone!</p>
]]></content:encoded>
	</item>
</channel>
</rss>

