Skip to Main Content
MooTools 1.3 Cookbook
book

MooTools 1.3 Cookbook

by Jay L Johnston
July 2011
Intermediate to advanced content levelIntermediate to advanced
276 pages
5h 11m
English
Packt Publishing
Content preview from MooTools 1.3 Cookbook

Chapter 10. Enough Is Never Enough: Extending MooTools

MooTools, an extensible JavaScript library, begins with a base Class and then Implements and Extends classes into useful and reusable objects.

Implement the recipes in this chapter to extend what MooTools can do for you:

  • Working directly with the base class, Class
  • Extending and implementing MooTools classes
  • Extending and implementing MooTools elements

Making a Corvette out of a car—extending the base class

The "base class" is a function, a method, that allows extension. Just what does extending a class entail? Buckle up and let us take a drive.

Getting ready

Just to show the output of our work, create a DIV that will be our canvas.

<div id="mycanvas"></div>

How to do it...

Creating a class from the ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Jump Start Web Performance

Jump Start Web Performance

Craig Buckler

Publisher Resources

ISBN: 9781849515689Other