history of jquery

27
jQuery Past, Present, and Future John Resig (ejohn.org)

Upload: jeresig

Post on 27-Jun-2015

12.918 views

Category:

Technology


0 download

DESCRIPTION

An introductory overview of the history of the jQuery library (up until present) - and then going beyond and looking at its future.

TRANSCRIPT

Page 1: History of jQuery

jQueryPast, Present, and Future

John Resig (ejohn.org)

Page 2: History of jQuery

Inspiration✦ Simon Willison’s getElementsBySelector✦ Dean Edwards’ cssQuery✦ Dean Edwards’ addEvent✦ Prototype✦ Behavior✦ moo.fx

Page 3: History of jQuery
Page 4: History of jQuery

The Beginning✦ Started August of ’05✦ http://ejohn.org/blog/selectors-in-javascript/

✦ $(’#foo ol li’) .set(’title’,’List Items!’) .bind(’click’,function(){alert(’Hello!’);}) .select(’.tmp’) .style(’color’,’white’) .select(’.foo’) .style(’background’,’red’);

✦ jSelect!

Page 5: History of jQuery

First Implementation✦ http://ejohn.org/apps/jselect/selector.js✦ $(document).bind(”ready”, init);

var rows = $(”#table tr:gt(0)”); $(”#table th”).bind(”click”,function(){ if ( removeClass( this, “asc” ) ) { addClass( this, “desc” ); rows.reverse(); } else { removeClass( this, “desc” ); addClass( this, “asc” ); rows.sort( ofType(this).n ); } })

Page 6: History of jQuery

First Implementation✦ function sort(f) {

cur = cur.sort(function(a,b){ if ( typeof f == ‘object’ ) var ret = f(a,b); else var ret = genericSort(a,b,f); if ( a < b ) b.parentNode.insertBefore( a, b ); else if ( a > b ) a.parentNode.insertBefore( b, a ); return ret; }); return this; } function reverse() { cur[0].parentNode.appendChild( cur[0] ); for ( var i = 1; i < cur.length; i++ ) cur[i-1].parentNode.insertBefore( cur[i], cur[i-1] ); cur = cur.reverse(); return this; }

Page 7: History of jQuery

Expression Parsing✦ var t = “[title]”;

var re = new RegExp( “^\\[([a-z0-9-]+)(~?\\^?=?)’?([^’]*)’?\\]”, “i” ); var m = re.exec(t); t = t.replace( re, “” ); alert( t + “---” + m[1] + “---” + m[2] );

Page 8: History of jQuery

Release!✦ Released at BarCamp NYC (Jan 2006)✦ “New Wave JavaScript”✦ Hit Digg and del.icio.us/popular✦ CSS + XPath✦ DOM Modification✦ Events✦ moo.fx-rewrite Animations

Page 9: History of jQuery
Page 10: History of jQuery

Download Builder

Page 11: History of jQuery

First Plugin ✦ 11 days later...✦ JSON plugin✦ “Unlike Prototype, jQuery doesn’t mess

around with built-in JavaScript objects. It’s new—too new to have a version number!—but I’ve been writing some code with it and enjoying it.”

✦ http://mg.to/2006/01/25/json-for-jquery

Page 12: History of jQuery

Initial Choices✦ The “$” war

✦ .style✦ .onclick✦ $(“id”) -> DOMElement

DOMElement.onclick = jQuery method✦ Creative Commons -> MIT✦ No Ajax! -> Ajax!

Page 13: History of jQuery

“jQuery 2”✦ May ‘06

✦ <script type=”text/jquery”> pre: css ‘background’ ‘#212121’ css ‘color’ ‘#0F0’ css ‘padding’ ‘10px’ css ‘font-size’ ‘14px’ body: prepend ‘<h1>jquery<sup>2</sup></h1>’ input:first: click compile input:last: click run </script>

Page 14: History of jQuery

Early Events✦ SVN (May ‘06) / Trac✦ Drupal✦ Thickbox (April ‘06)✦ Version 1.0 (August ‘06)

Page 15: History of jQuery

Teenage jQuery✦ jQuery Magazine✦ “Why jQuery is better”

Page 16: History of jQuery

Later Events✦ Plugins Repository✦ Evangelism Team

Page 17: History of jQuery

Progress✦ 13 Releases (not including previews)✦ 4200 Mailing List Subscribers✦ 48% Developer Coverage (Ajaxian.com)

Page 18: History of jQuery

Who uses jQuery?• Digg• Google• NBC• MSNBC• Amazon• Intel• BBC• AOL• Oracle• Cisco• Newsweek• Techonorati• Washington Post• Sourceforge• American Eagle• Salesforce• Newsgator• Boston Globe• My YearBook• New York Post

• Miami Herald• Food Network• REI• The Onion• FeedBurner• PokerRoom• Warner Bros.• Def Jam• Classmates• Fandango• Pandora• isoHunt• Ask A Ninja• Ars Technica• Linux.com• Joost• Barack Obama• Nintendo• and more!

Page 19: History of jQuery

jQuery: Now✦ jQuery 1.2.1✦ jQuery UI

Page 20: History of jQuery

jQuery UI✦ First major new project since jQuery✦ Important new direction for the project✦ Huge boost to interest

Page 21: History of jQuery

Future✦ jQuery Test Suite✦ jQuery UI✦ Internationalization✦ Forums

Page 22: History of jQuery

Test Suite✦ Distributed

✦ Run in any browser✦ Submit results back to central server

✦ UI Testing✦ Automation✦ Manual user tests

Page 23: History of jQuery

jQuery UI✦ Refine, improve✦ Release new widgets✦ More corporate support

Page 24: History of jQuery

Internationalization✦ Individual language sites✦ Dedicated documentation

Page 25: History of jQuery

Forums✦ Mailing List just isn’t scaling✦ Very frequent request✦ Probably better suited to audience

Page 26: History of jQuery

Questions?

Page 27: History of jQuery