2011-04

The Singleton pattern in JavaScript: not needed

[2011-04-12] dev, javascript, jslang
This post argues that the singleton pattern is usually not needed in JavaScript, because you can directly create objects. It then slightly backpedals from that position and shows you code skeletons that you can use if your needs go beyond the basics.

The Singleton pattern and its simplest implementation in Java

[2011-04-10] dev, java
This post motivates the Singleton design pattern and explains its implementation in Java.

Information management classics: Lifestreams (1996)

[2011-04-08] info mgmt, computers
Lifestreams [1] were created in 1996 to correct some of the shortcomings of document management when used for personal information management. Even today, document management is still the dominant way of information management, both conceptually and as a user interface metaphor. Some of the shortcomings are:

How Google Chrome reduces the processor load of webapps

[2011-04-06] browser, computers, chrome
With the web’s popularity, it is common for web browsers to have many open tabs at the same time. Processor load can significantly increase in such a case. Google Chrome has implemented several measures to help with that:

JavaScript: an overview of the regular expression API

[2011-04-01] dev, javascript, jslang, regexp
Updates: This post gives an overview of the JavaScript API for regular expressions. It does not, however, go into details about regular expression syntax, so you should already be familiar with it.

Using HTML5 figures in today’s browsers

[2011-04-01] dev, html5
HTML5 includes tags for figures and figure captions. This post explains how to use them in modern browsers.

2011-03

A first look at the upcoming JavaScript modules

[2011-03-27] esnext, dev, javascript
Update 2012-10-22: Note that this feature is still actively being worked on and in flux.

Judging by a tweet by David Herman, he is excited about something (he is shouting!) and so should we be:

MODULES FOR ECMASCRIPT, Y'ALL. MODULES FOR ECMASCRIPT. THAT IS ALL. [@littlecalculist]
This means: ECMAScript Harmony (or ECMAScript.next [1]), as it is currently being planned, will have modules. This post gives you a first look, summarizing the material at [2].

JavaScript: how it all began

[2011-03-23] dev, javascript, jslang, jshistory
This post presents a brief history of how Brendan Eich created JavaScript and what influenced its design decisions.

Mac tips (not only) for switchers

[2011-03-22] apple, hack, computers, mac
If you are new to the Mac, everything can feel a bit off. This post tries to help. And might even teach you something new if you are already familiar with the Mac. I am also mentioning some advanced things which should be interesting for programmers and people coming from Linux.

Make node.js code pretty via a generator-based library

[2011-03-19] esnext, dev, nodejs, javascript
The JavaScript server environment node.js has an intriguing approach to coding: Do other things while waiting for results from, say, a database. But don’t use threads to juggle those things, use continuations. This is similar to what client-side JavaScript code (such as Ajax calls) already looks like. Not having to create threads saves a lot of overhead when loads are high. Multi-core and multi-processor systems can still be supported, by scheduling one “instance” of node.js per core/processor.

The only problem with node.js code: You get one nested function expression for each outside request you make.