Quantcast
Channel: Dreaming In JavaScript
Browsing latest articles
Browse All 10 View Live

Image may be NSFW.
Clik here to view.

Sort of Confusing

Some of the worst JavaScript code I have seen has to do with sorting data. JavaScript has a flexible array sort method, but it takes a while to get the hang of using it. Programmers seem to do fine...

View Article



Image may be NSFW.
Clik here to view.

Do While Once in a While

The other day, a programmer I follow on Twitter was pleased because he had found a good use for a do/while loop. When a programmer gets excited by a loop construct, you know something is wrong. The...

View Article

Image may be NSFW.
Clik here to view.

Falsies

We call values that loosely evaluate to false “falsy.” What does “loosely” mean in this context? There are two comparison operators to test equivalence in JavaScript (== and ===). The first is loose,...

View Article

Image may be NSFW.
Clik here to view.

JavaScript Functions are Weird, Too

Remember when I said that JavaScript arrays are weird because they are also objects? Aside from their numbered elements, they can have, in addition, hash elements (a key and a value). Believe it or...

View Article

Image may be NSFW.
Clik here to view.

Default Parameters, Episode V

I keep a pretty close eye on the searches that bring people to this blog. A lot of you are searching for how to sort in JavaScript (I’ll have to go into more detail on sorting soon). And a whole mess...

View Article


Image may be NSFW.
Clik here to view.

Eliminating Duplicates

Yesterday I ran into a programming problem and I didn’t like any of the solutions I came up with. I went to bed kind of grouchy about it. Here’s the problem: Given a huge number of strings, return an...

View Article

Image may be NSFW.
Clik here to view.

Combinations and Permutations in JavaScript

In JavaScript Numbers Can Bite, I talked about a problem that can crop up in JavaScript when you’re doing calculations with integers. At the end of the post I hinted at a better way to write the...

View Article

Image may be NSFW.
Clik here to view.

Review: Balsamiq Mockups

How do you design the layout of a website? My favorite way is with Balsamiq Mockups, which I first heard about at Ajaxian. Why Balsamiq? Very short learning curve. Anyone on the team can make changes...

View Article


Image may be NSFW.
Clik here to view.

Bitwise, Byte Foolish?

Farrah Fawcett says you should use JavaScript Bitwise Operators

View Article


Image may be NSFW.
Clik here to view.

Sentinels in JavaScript

Alternatives to traditional sentinel values.

View Article
Browsing latest articles
Browse All 10 View Live




Latest Images