A collection of code exercises to use mentoring people in JavaScript using jQuery.
The principle behind these code exercises is to demonstrate what jquery can do, but also understand what jQuery is actually doing behind the scenes.
- Create a collapsable list using pure jQuery
- Emulate jQuery's toggleClass() with hasClass(), addClass() and removeClass()
- Emulate jQuery's toggleClass() without using jQuery (pure DOM + Strings + regex)
- Objects and Arrays
- Square bracket notation and dot notation
- object literals
- global variables and namespaces
- functions (function are objects too)
- object detection
- function scope
- function references
- callback / event-handler functions
- 'this'
- closures
- classes and instances
- class constructors
- prototype chain
- event bubbling and event capturing
- Steve Marshall: for guidance in structuring the code exercises.