I plan on writing up a full blog post once I have my copy of the book.
3,006 karma · joined October 10, 2006
I work at Khan Academy and the author of the books 'Pro JavaScript Techniques' and 'Secrets of the JavaScript Ninja'. I'm currently located in the Hudson Valley, NY.
I was in Y Combinator-funded startup during the summer of 2006 with Julia West ('juliamae') and Josh King ('skierx') working on peer-to-peer messaging over mobile devices.
Site: https://johnresig.com Email: jeresig at gmail.com
I plan on writing up a full blog post once I have my copy of the book.
I'm 100% fine with code criticism - I think you'll find no JS library more open to it than the jQuery project, we've shifted the code base many times over the years making large quality/performance/API improvements based upon criticism. That being said I have no interest in talking with people - valid code criticism or not - if they're personally attacking me as well.
It's rather amusing to see a case where I, unfortunately, fed the trolls trotted out as an example of future decision making. In this case the decision behind this was my own and largely done through my personal examination of the jQuery code base.
As to why jQuery moved to feature testing, we discussed that in the jQuery 1.3 release notes: http://docs.jquery.com/Release:jQuery_1.3
For with statements in particular, templating and scoped evaluation (I provide an example from the Firebug console in the book) are probably the two areas in which I've seen it most successfully used.
For code evaluation I only have to direct you to the creation of Coffeescript (an entirely evaluated language) whose innovations have directly influenced new versions of the ECMAScript language.
They have their place and when used sparingly, but effectively, the can be formidable parts of a web developer's arsenal.
So yeah, strike the last item from my list - I blame it solely on PasswordMaker.
I use a ton of tabs in my browser, in Firefox the tabs go off to the side and allow me to scroll through them (while still allowing me to read the title) whereas Chrome squishes the tabs into tiny micro-sized pills that are completely unreadable.
Additionally I use App Tabs in both browsers - but only in Firefox does it highlight when I've received an update (such as a message in Hip Chat or an email in Gmail).
The lack of integrated extensions in Chrome makes for a weaker overall experience. I use PasswordMaker to manage my passwords - works great in Firefox, can enter passwords into any field, but in Chrome it frequently doesn't detect a password field - and since it doesn't have context menu access I can't fill in my password. I end up having to open up Firefox just to get to my password.
So yeah, I still use Firefox for daily browsing, and Chrome for dev.
http://www.overstock.com/Electronics/Griffin-RoadTrip-iPhone...
Thanks for the details on this! We dug into our Wordpress and realized that W3 Total Cache was configured to block anything that had the word 'bot' as part of its user agent string (sigh). That's now fixed and live.
As to the redirect - that's actually a bit of devious magic on our end. Since jquery.it is hotlinking to our JavaScript and CSS we just added a bit of JavaScript to automatically redirect them to the right jQuery.com page:
if ( /jquery\.it/.test( window.location.hostname ) ) {
window.location = window.location.href.replace('y.it', 'y.com');
}
Thanks again for your pointers - looks like the jQuery 1.6.2 blog post is already showing up in the search results and jQuery.it is not in the first page of results (although "jquery 1.6.1" hasn't updated yet and jQuery.it is still there - I assume that it'll be remedied as the Google spider makes more progress). Thanks again!Looks like someone has submitted it to HN as well: http://news.ycombinator.com/item?id=2544698
<input type="checkbox" id="c"/>
$("#c").attr("checked") => false // 1.5.2
$("#c").attr("checked") => undefined // 1.6
$("#c").attr("checked") => undefined // 1.6.1
The user then checks the checkbox OR we set the check by doing .prop("checked", true) OR we set the check by doing [0].checked = true, the result would be: $("#c").attr("checked") => true // 1.5.2
$("#c").attr("checked") => undefined // 1.6
$("#c").attr("checked") => "checked" // 1.6.1
Note that if we had done .attr("checked", "checked") OR .attr("checked", true) to set the checked property then .attr("checked") would've returned "checked" in both 1.6 and 1.6.1.In short: In jQuery 1.6.1 .attr(BooleanAttribute) now returns either the name of the attribute (if true) or undefined (if false). Which is consistent with the rest of the API and with the DOM itself.
I should note that all of this is a moot point if you're using .prop("checked") - that will just return true/false consistently based upon the current checked state of the checkbox.
The bug and commit are as follows: http://bugs.jquery.com/ticket/9079 https://github.com/jquery/jquery/commit/a9d9f8c5422f171d9c45...
You can start using this code right now with the following version of jQuery: http://code.jquery.com/jquery-git.js
Hope this helps!
It's going to be a challenge to figure out the right UI idioms for the project, less so getting it working on a bunch of platforms giving the technology stack (open web technologies). Right now that's my biggest concern. Once we figure out how the interactions should work then the table/mobile world is our oyster.
That's precisely it. Being who I am, I'm going to be building everything with Open Web technologies and most likely built on top of jQuery Mobile. The iPad is just serving as a good initial platform to target and test on before expanding massively.
I wouldn't be surprised if much of the work that happens on the tablet version of the site gets back-ported to the main site itself (as things like tablets and mobile devices tend to encourage minimalist UIs and a larger emphasis on what the user is attempting to achieve).
I did work for the One Laptop Per Child project in the past, I'm a strong advocate for getting useful resources out to as many people as possible - regardless of their means.
We're going to have a 1.6.1 release within the week. Thank you for your bug report!