Your SlideShare is downloading. ×
Sizzle jQCon San Francisco 2012
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

Sizzle jQCon San Francisco 2012

3,153
views

Published on

Published in: Technology, Business

0 Comments
3 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
3,153
On Slideshare
0
From Embeds
0
Number of Embeds
5
Actions
Shares
0
Downloads
42
Comments
0
Likes
3
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • Welcome, so excited about what we have in store for Sizzle in jQuery 1.8.\nFirst, let’s talk about performance\n
  • Many things stayed the same\n
  • To sum up\n- Based on all of the perf tests I’ve done so far, we have excellent codepaths to QSA and matchesSelector\n- So, we’ve covered some performance stuff. Now the next question is, what did we fix?\n
  • To sum up\n- Based on all of the perf tests I’ve done so far, we have excellent codepaths to QSA and matchesSelector\n- So, we’ve covered some performance stuff. Now the next question is, what did we fix?\n
  • To sum up\n- Based on all of the perf tests I’ve done so far, we have excellent codepaths to QSA and matchesSelector\n- So, we’ve covered some performance stuff. Now the next question is, what did we fix?\n
  • To sum up\n- Based on all of the perf tests I’ve done so far, we have excellent codepaths to QSA and matchesSelector\n- So, we’ve covered some performance stuff. Now the next question is, what did we fix?\n
  • - event delegation\n- id, tag, class\n- jQuery(something).find(ID)\n
  • - actually that selector would work if the special characters were escaped and :checkers was a custom pseudo.\n- OK, but there were actually bugs\n
  • Every browser has bugs in querySelectorAll, even webkit.\n- If you know what I did in the last version of jQuery, you’ll know about my long standing relationship with attributes. IE8’s QSA doesn’t handle boolean attributes very well.\n
  • Every browser has bugs in querySelectorAll, even webkit.\n- If you know what I did in the last version of jQuery, you’ll know about my long standing relationship with attributes. IE8’s QSA doesn’t handle boolean attributes very well.\n
  • Every browser has bugs in querySelectorAll, even webkit.\n- If you know what I did in the last version of jQuery, you’ll know about my long standing relationship with attributes. IE8’s QSA doesn’t handle boolean attributes very well.\n
  • Every browser has bugs in querySelectorAll, even webkit.\n- If you know what I did in the last version of jQuery, you’ll know about my long standing relationship with attributes. IE8’s QSA doesn’t handle boolean attributes very well.\n
  • Every browser has bugs in querySelectorAll, even webkit.\n- If you know what I did in the last version of jQuery, you’ll know about my long standing relationship with attributes. IE8’s QSA doesn’t handle boolean attributes very well.\n
  • The only acceptable division in the selectors spec is comma, which made this easy to fix.\nSo you might be wondering what’s next.\n
  • The only acceptable division in the selectors spec is comma, which made this easy to fix.\nSo you might be wondering what’s next.\n
  • The only acceptable division in the selectors spec is comma, which made this easy to fix.\nSo you might be wondering what’s next.\n
  • The only acceptable division in the selectors spec is comma, which made this easy to fix.\nSo you might be wondering what’s next.\n
  • The only acceptable division in the selectors spec is comma, which made this easy to fix.\nSo you might be wondering what’s next.\n
  • The only acceptable division in the selectors spec is comma, which made this easy to fix.\nSo you might be wondering what’s next.\n
  • And I’m here to tell you, you are not prepared.\n
  • Everything I’ve told you about Sizzle today might change before 1.8 is released. It’s true I rewrote Sizzle. I might just rewrite it again.\n
  • Everything I’ve told you about Sizzle today might change before 1.8 is released. It’s true I rewrote Sizzle. I might just rewrite it again.\n
  • Everything I’ve told you about Sizzle today might change before 1.8 is released. It’s true I rewrote Sizzle. I might just rewrite it again.\n
  • Everything I’ve told you about Sizzle today might change before 1.8 is released. It’s true I rewrote Sizzle. I might just rewrite it again.\n
  • Everything I’ve told you about Sizzle today might change before 1.8 is released. It’s true I rewrote Sizzle. I might just rewrite it again.\n
  • Everything I’ve told you about Sizzle today might change before 1.8 is released. It’s true I rewrote Sizzle. I might just rewrite it again.\n
  • - maybe even with a pull request\n- the issues on the jQuery bugs site will be migrated\n- stale google group, needs more life\n\n
  • - maybe even with a pull request\n- the issues on the jQuery bugs site will be migrated\n- stale google group, needs more life\n\n
  • - maybe even with a pull request\n- the issues on the jQuery bugs site will be migrated\n- stale google group, needs more life\n\n
  • - maybe even with a pull request\n- the issues on the jQuery bugs site will be migrated\n- stale google group, needs more life\n\n
  • - maybe even with a pull request\n- the issues on the jQuery bugs site will be migrated\n- stale google group, needs more life\n\n
  • \n
  • \n
  • Transcript

    • 1. SizzleWhat’s new in jQuery 1.8?Timmy Willison
    • 2. PerformanceWat? Fast?
    • 3. Performance
    • 4. PerformanceMatching/filtering improved consistently by ~10% quickIs from event.js moved to Sizzle.filter
    • 5. PerformanceMatching/filtering improved consistently by ~10% quickIs from event.js moved to Sizzle.filterSimple selectors (id only, tag only, class only) improvedby about 5% overall
    • 6. PerformanceMatching/filtering improved consistently by ~10% quickIs from event.js moved to Sizzle.filterSimple selectors (id only, tag only, class only) improvedby about 5% overallElement-rooted ID selections: 300% improvement
    • 7. PerformanceMatching/filtering improved consistently by ~10% quickIs from event.js moved to Sizzle.filterSimple selectors (id only, tag only, class only) improvedby about 5% overallElement-rooted ID selections: 300% improvementShorter codepaths to querySelectorAll andmatchesSelector
    • 8. Filtering and matching 1.7.2 1.8*Based on http://jsperf.com/jquery-id-init/4 andhttp://jsperf.com/jquery-id-init/6 (higher is better)
    • 9. Filtering and matching 1.7.2 1.8100755025 0 event trigger simple complex element-rooted ID*Based on http://jsperf.com/jquery-id-init/4 andhttp://jsperf.com/jquery-id-init/6 (higher is better)
    • 10. Sizzle(“div.&*( ~ timmy:checkers [dave^=‘core’]”).length === 0
    • 11. Ok, there were bugs.
    • 12. Ok, there were bugs.Improved QSA/matchesSelector bug-detection
    • 13. Ok, there were bugs.Improved QSA/matchesSelector bug-detection bypasses in certain browsers on certain selectors
    • 14. Ok, there were bugs.Improved QSA/matchesSelector bug-detection bypasses in certain browsers on certain selectors class[^$*]=”” (Opera/IE9)
    • 15. Ok, there were bugs.Improved QSA/matchesSelector bug-detection bypasses in certain browsers on certain selectors class[^$*]=”” (Opera/IE9) :checked won’t return selected options as per the spec in versions of Chrome/Safari/Opera
    • 16. Ok, there were bugs.Improved QSA/matchesSelector bug-detection bypasses in certain browsers on certain selectors class[^$*]=”” (Opera/IE9) :checked won’t return selected options as per the spec in versions of Chrome/Safari/Opera attroperties IE8 (attributes are everywhere!)
    • 17. Combinators ( div ~ em + u > * )
    • 18. Combinators ( div ~ em + u > * ) When using multiple combinators in the same selector, some possible matches were being lost
    • 19. Combinators ( div ~ em + u > * ) When using multiple combinators in the same selector, some possible matches were being lostElement-rooted querySelectorAll with divisions
    • 20. Combinators ( div ~ em + u > * ) When using multiple combinators in the same selector, some possible matches were being lostElement-rooted querySelectorAll with divisions elem.querySelectorAll(“div, div > em”);
    • 21. Combinators ( div ~ em + u > * ) When using multiple combinators in the same selector, some possible matches were being lostElement-rooted querySelectorAll with divisions elem.querySelectorAll(“div, div > em”);Unicode validation (improved character encoding per spec)
    • 22. Combinators ( div ~ em + u > * ) When using multiple combinators in the same selector, some possible matches were being lostElement-rooted querySelectorAll with divisions elem.querySelectorAll(“div, div > em”);Unicode validation (improved character encoding per spec)Several little edge cases
    • 23. Coming UpYou are not prepared.
    • 24. Coming Up
    • 25. Coming UpSizzle may still see major changes before 1.8 release
    • 26. Coming UpSizzle may still see major changes before 1.8 release Explore implementing a compiler to convert a selector into a function in order to avoid ever looping over elements more than once.
    • 27. Coming UpSizzle may still see major changes before 1.8 release Explore implementing a compiler to convert a selector into a function in order to avoid ever looping over elements more than once.More css3 selectors (after 1.8)
    • 28. Coming UpSizzle may still see major changes before 1.8 release Explore implementing a compiler to convert a selector into a function in order to avoid ever looping over elements more than once.More css3 selectors (after 1.8)Provide even more selector validation
    • 29. Coming UpSizzle may still see major changes before 1.8 release Explore implementing a compiler to convert a selector into a function in order to avoid ever looping over elements more than once.More css3 selectors (after 1.8)Provide even more selector validation e.g. [attr=”value”] - identifier vs. string
    • 30. Coming UpSizzle may still see major changes before 1.8 release Explore implementing a compiler to convert a selector into a function in order to avoid ever looping over elements more than once.More css3 selectors (after 1.8)Provide even more selector validation e.g. [attr=”value”] - identifier vs. stringThere are still bugs!
    • 31. Contributing
    • 32. ContributingSubmit an issue at http://github.com/jquery/sizzle
    • 33. ContributingSubmit an issue at http://github.com/jquery/sizzle Pick an issue and dig in
    • 34. ContributingSubmit an issue at http://github.com/jquery/sizzle Pick an issue and dig inDiscussion in #jquery-dev, longer discussion in thepublic Sizzle google group
    • 35. ContributingSubmit an issue at http://github.com/jquery/sizzle Pick an issue and dig inDiscussion in #jquery-dev, longer discussion in thepublic Sizzle google groupSame styleguide, development workflow as jQuery
    • 36. ContributingSubmit an issue at http://github.com/jquery/sizzle Pick an issue and dig inDiscussion in #jquery-dev, longer discussion in thepublic Sizzle google groupSame styleguide, development workflow as jQuery See jQuery’s readme (http://github.com/jquery/jquery)
    • 37. Contributing (ask me) timmywil in #jquery or #jquery-dev @timmywil on the tweeters and the githubs
    • 38. Up nextjQuery UI updatesScott Gonzalez