Tuesday, December 23rd, 2008

Thomas Fuchs comes back with some JavaScript tips

Category: JavaScript

Thomas has been busy working on freckle, but has jumped back onto his blog again to give us some short tips: Preventing console.log breakage We have all been there. After a serious Firebug session, you forget to take out the console statements. Or, maybe you like to keep them in for the future. To be Read the rest…

Posted by Dion Almaer at 6:57 am

2.7 rating from 24 votes

Monday, December 22nd, 2008

Towards Better Reuse: Traits in JavaScript

Category: JavaScript

From way back in 1987 comes a quote that summarizes how many feel about the state of object-oriented programming: Multiple inheritance is good, but there is no good way to do it. Joey Hurst wrote in to point us to his pet project–JSTraits–which aims to address this issue in JavaScript by providing an implementation of Read the rest…

Posted by Ben Galbraith at 11:42 am

3.4 rating from 18 votes

jQuery Gestures

Category: JavaScript, jQuery, Library

Adrien Friggeri has taken the music player ui and spent some time to create a really nice gestures library that allows you to add mouse gestures to a web page, supports complex (i.e. sequences of) gestures and provides visual feedback through the use of a canvas element. Example code looks like this: < View plain Read the rest…

Posted by Dion Almaer at 8:28 am

3.9 rating from 39 votes

mimeparse: now in JavaScript

Category: JavaScript

< View plain text > javascript Mimeparse.bestMatch([‘application/xbel+xml’, ‘text/xml’], ‘text/*;q=0.5,*/*; q=0.1′); The above code is from a JavaScript port of Joe Gregorio’s mimeparse library that “provides basic functions for handling mime-types. It can handle matching mime-types against a list of media-ranges. See section 14.1 of the HTTP specification RFC 2616 for a complete explanation.” Using it Read the rest…

Posted by Dion Almaer at 5:18 am

2.4 rating from 9 votes

Friday, December 19th, 2008

DWR 3.0 near final release with RC

Category: Java, JavaScript, Library

Joe Walker and team have announced the first RC for DWR 3.0. We asked Joe to tell us what is new: DWR now supports: varargs method overloading typed parameters binary file upload/download it has a set of new types it can marshall DWR will let you use JavaScript to implement Java interfaces (e.g. to register Read the rest…

Posted by Dion Almaer at 6:02 am
Comment here

4.3 rating from 18 votes

DLINK: automatic link annotation

Category: JavaScript, Showcase

David King has created a small JavaScript library dlink that styles your links to let the user know if the link is internal, external, a subdomain, an anchor on the same page, or an email link. To setup, you can simply: < View plain text > HTML <script type="text/javascript" src=""></script>   <!– use class=dlink –> Read the rest…

Posted by Dion Almaer at 12:01 am

4.3 rating from 41 votes

Thursday, December 18th, 2008

Pixastic: JavaScript Image Manipulation Library

Category: Canvas, JavaScript

Pixastic uses <canvas>’s ability to expose raw pixel information to perform Photoshop-style image manipulation effects all in your standards-based browser. For an example of Pixastic in action, the library’s authors have built a cute little Photoshop clone in a browser: Here’s an example of using the underlying API: < View plain text > javascript var Read the rest…

Posted by Ben Galbraith at 11:57 am

3.8 rating from 31 votes

Wednesday, December 17th, 2008

OilCan: Grease up your Android browser

Category: Java, JavaScript, Mobile

Jeffrey Sharkey has created OilCan a thin wrapper on top of the WebKit shipping on Android that allows you to install userscripts that allow you to access to Android “Intents”. Intents are very nice abstractions that allow you to access large components and reuse them in different ways. Romain Guy has a nice post on Read the rest…

Posted by Dion Almaer at 6:13 am

4 rating from 6 votes

Tuesday, December 16th, 2008

Census 2: Benchmarking RIAs Rebooted

Category: JavaScript

Alex Russell decided to rewrite and create Census 2 to act as a new benchmark for various RIA techniques. This is based on the the original Census benchmark done by James Ward of Adobe. There are several goals of this re-write: Fairness. Tests need to be run multiple times for them to be representative in Read the rest…

Posted by Dion Almaer at 2:00 pm
Comment here

3.6 rating from 16 votes

Interfaces in JavaScript

Category: Java, JavaScript

The UML diagram above is from Matt Prokes as he creates Java-like interfaces for JavaScript. He has a full example: An example of an object which requires an implementation of the interface. < View plain text > javascript //This code is valid, and the execution will be successful. function executeInterface1(executeThis){   var castedIface = executeThis.cast(‘TestInterface’); Read the rest…

Posted by Dion Almaer at 12:51 pm

1.9 rating from 23 votes

Monday, December 15th, 2008

PNG support in IE6 that reclaims background repetition and position

Category: JavaScript, Library

Drew Diller has created a helper library in the “yup, you still have to get things working in IE 6” department. DD_belatedPNG adds PNG support to IE6 that works with background-repeat and background-position. You just do this: < View plain text > HTML <!–[if IE 6]> <script src="DD_belatedPNG.js"></script> <script>    DD_belatedPNG.fix(‘.png_bg’); /* EXAMPLE */   Read the rest…

Posted by Dion Almaer at 7:24 am

4.2 rating from 37 votes

Friday, December 12th, 2008

YQL – converting the web to JSON with mock SQL

Category: JavaScript, JSON

I like getting data from the web and I love JSON – as it is easy to use. The issue is that not many things on the web come as JSON from the get-go. Hence we need converters. You can use cURL and beautiful soup or roll your own hell of regular expressions. Alternatively you Read the rest…

Posted by Chris Heilmann at 4:20 pm

4.3 rating from 52 votes

Cappuccino 0.6 Released

Category: Apple, Framework, JavaScript

The Cappucinno team has a new release, 0.6 that include: New language addition to Objective-J: The @accessors keyword to eliminate the boiler plate code of writing setters and getters. Read more about it here. Support for more classes like CPTimer. Performance improvements all around, but especially in Objective-J thanks to a major rewrite of the Read the rest…

Posted by Dion Almaer at 7:06 am
Comment here

3.4 rating from 24 votes

More JavaScript Inheritance; Prototypes vs. Closures

Category: Examples, JavaScript

Steffen Rusitschka has a nice detailed post on inheritance with JavaScript, different ways you can go, and side effects of the decision. From, < View plain text > javascript var A = function(){}; // This is the constructor of "A" A.prototype.value = 1; A.prototype.test = function() { alert(this.value); } var a = new A(); // Read the rest…

Posted by Dion Almaer at 4:05 am

2.4 rating from 27 votes

Tuesday, December 9th, 2008

You Leaked on my JavaScript!

Category: JavaScript

As soon as I read John’s post on JavaScript Language Abstractions I knew that it would draw a lot of chatter and fuzz. John started with: Pyjamas, GWT, and Objective-J all hinge around a central concept: Abstracting away the authoring of JavaScript-heavy web applications by allowing the developer to program entirely in their natively language Read the rest…

Posted by Dion Almaer at 7:26 am

4 rating from 27 votes

Monday, December 8th, 2008

Massively parallel crowd sourced JavaScript app server; SETI for JS

Category: JavaScript, Server

Malte Ubl is having a lot of fun here :) He has created a “massively parallel crowd-sourced JavaScript app server cloud” a.k.a. SETI for running JavaScript code. This is how it works: When a user makes a request to the site …the request is handled by a Google App Engine application …that puts the request Read the rest…

Posted by Dion Almaer at 5:56 am

4.1 rating from 18 votes