Archive for the ‘Uncategorized’ Category

Some examples of Mootools in action

October 27th, 2006 by Aaron N.

I spotted this post over at the Mootools forums and thought I’d share. It’s really amazing how much you can get out of this little library. One of the things our new framework does is let us create functionality like this and deploy it so any producer/engineer can use it with relatively little effort.

Tabs

The original author asked me for a moo-conversion, work is in progress. Will refactor still much of the code and add support for Dragging into tabcontent (Dragging over a tab activates it).

http://dev.digitarald.de/tabs.html

Playground Dragging (Reverse Dragging)

Dragging reversed, wonky because onStart and onComplete have this 10ms delay, so in some situations the position is changing.

http://dev.digitarald.de/drag.html

Fly-over-background

Scrolling effect, like the effect in flash used on some nice sites. Scrolling from content to content that is attached to a big background image. Just a performance check ;)

http://dev.digitarald.de/tile.html

Ghost Dragging

Shopping Card dragging? Drag your favorite element and drop a copy of it, like in Rich Client Shopping cards or Item-to-Category. Very basic, added my personal spice with ajax and more checks inside my own rich client project ;)

http://dev.digitarald.de/ghostdrag.html

More to come (Better Lightbox, mooSelectBox, conversion of Floating Windows).

Some early blog posts on MooTools w/ examples

September 20th, 2006 by Aaron N.

MooTools continues to impress me. Check out the Class.implement and Class.extend functionality in this great article from Cory Hudson (there are numerous code examples).

mootools implements a class inheritance scheme that is inspired by Dean Edwards’ wonderful Base class. Creating a class is similar to Prototype, but now you don’t ever have to think about the prototype object when you define the class…

…mootools supports multiple inheritance in a Ruby mixin style with the Class.implement() method. Using the implement method of an existing class, that class can inherit methods and properties from another class or object. Unlike Class.extend(), the implement method is called on the class you are modifying, not on the object being copied. This method can be used to support multiple inheritance.

And here’s another article from Cory on MooTools numerous helpful utility functions:

The new mootools JavaScript framework has quickly impressed me with its design and usefulness. The library was clearly written to meet real programmers’ needs while working in JavaScript. Just take a look at some of the new utility functions and methods it provides.

Note: This article covers functions and methods found in the Array.js and Function.js modules of mootools.

Optimizing Javascript for IE

September 19th, 2006 by Aaron N.

A while back I posted articles on memory leaks and how to avoid them (read them! seriously). In the process of learning that lesson, I had to rethink the way I wrote my code a little which was a little painful. Actually, every week or so I realize there’s a better way to do something and when I look at code I wrote a month ago I want to rewrite it.

So this article, is kind of frustrating, as it highlights a level of javascript I’d previously not considered much and, as I think about it now, wish I didn’t have to. Specifically, this article talks about how the IE javascript engine works with IE’s DOM engine and how to avoid expensive namespace lookups. It’s worth reading, but having read it I find the knowledge itself annoying. Maybe this stuff would be easier to write in Assembly…

via ajaxian (of course):

Peter Gurevich and Justin Rogers from Microsoft’s IE team recently wrote a blog entitled ‘IE + JavaScript Performance Recommendations – Part 1‘. It’s an interesting read, containing such tips as:

  • Precede your variables with var if you are truly defining them in the current scope
  • Cache Variables Whenever Possible
  • Cache Function Pointers at all costs
  • Cache Function Pointers at all costs

Yahoo! Web Services Using JSON

June 2nd, 2006 by markbult

by Douglas Crockford (Yahoo!)
June 14, 2006 from 6 – 9:30 p.m.
6 p.m. – Reception; 7 p.m. – Presentation

JSON is rendering the “X” in AJAX superfluous. JSON or JavaScript Object Notation is a universal data format. It provides an uncommonly effective bridge for moving data between systems and between languages. JSON is also really simple. In fact, many of the Yahoo! Web Services provide JSON as an alternate output format to XML. Read the rest of this entry »