Activate your free membership today | Log-in

Wednesday, September 24th, 2008

Detailed JavaScript and Processing.js from John Resig

Category: Canvas, Presentation

<>p>John Resig has given some great talks recently, and just posted about some of them.

First, we have his interactive learning area where the presentation is just a JavaScript application that you can play with. Double click on the code, make a change, and save away!

The talk goes into the innards of the language that we are know, love, or at least deal with:

  • Defining Functions
  • Named Functions
  • Functions as Objects
  • Context
  • Instantiation
  • Flexible Arguments
  • Closures
  • Temporary Scope
  • Function Prototypes
  • Instance Type
  • Inheritance
  • Built-in Prototypes
  • Enforcing Function Context
  • Bonus: Function Length

The goal of all of this, is that after going through the presentation you should understand the following:

JAVASCRIPT:
  1.  
  2. // The .bind method from Prototype.js
  3. Function.prototype.bind = function(){
  4.   var fn = this, args = Array.prototype.slice.call(arguments), object = args.shift();
  5.   return function() {
  6.     return fn.apply(object,
  7.       args.concat(Array.prototype.slice.call(arguments)));
  8.   };
  9. };
  10.  

Next up is his talk on Canvas, Processing and Processing.js. Everytime I see this stuff it makes me smile. Amazing visualizations are here:

Related Content:

Posted by Dion Almaer at 6:00 am
Comment here

+++--
3 rating from 24 votes

Comments Here »

Comments feed TrackBack URI

Leave a comment

You must be logged in to post a comment.