Update 2013-08-25: Blog post “
Protecting objects in JavaScript” (
Object.preventExtensions(),
Object.seal(),
Object.freeze()).
Properties determine the state of an object in JavaScript. This blog post examines in detail how they work.
The basic idea of
Markdown is simple:
To create a document, one writes plain text (bullet lists are lines that start with dashes, styles are written **bold** and *italics*, etc.). To display a document, the plain text is converted to HTML.
That gives you the best of both worlds: the plain text is to write (much easier than HTML), store and transfer; the rendered HTML is nice to look at.
It is amazing how popular Markdown has become: GitHub supports it for files such as readmes and gists; Stack Overflow uses it for comments; Lean Publishing supports no other format for submitting books; many blog engines let you write posts in it; etc.
Thanks to
Rick Waldron, we have a
detailed account of the decisions regarding ECMAScript.next that were made by TC39
[1] during its meeting from September 18-20, 2012. This blog post summarizes and explains the highlights.
[2012-10-15]
dev, javascript
2013-12-23: A new
blog post on ParallelJS (as River Trail is now called) supersedes this post.
River Trail is a set of mechanisms that enable a new functional style of parallel programming in JavaScript. An initial prototype was developed by Intel. Recently, work has started to bring it to Firefox.
[2012-10-11]
jsshell, dev, shell, mac
The Mac OS X shell has several Mac-only commands for communicating with the graphical user interface (GUI). They are useful in three cases: First, when switching back and forth between shell and GUI. Second, when interacting with the system from a language that is not Objective C or AppleScript: Bash, Node.js
[1], Python etc.
[This post is part of a
series on the special property
__proto__]
Bracketing variable names with double underscores is a tradition in Python that JavaScript has borrowed a few times, most prominently for the property __proto__ [1] (which is currently non-standard, but will become part of ECMAScript 6). For Python, the following pronounciation has been suggested by Ned Batchelder:
[This post is part of a
series on the special property
__proto__]
This blog post looks at the special property __proto__, which allows you to get and set the prototype of an object. In order to understand this post, you should be familiar with JavaScript’s prototypal inheritance [1].
Quoting
Wikipedia:
A quine is a computer program which takes no input and produces a copy of its own source code as its only output.
@cowboy (Ben Alman) gives the
following example for JavaScript:
!function $(){console.log('!'+$+'()')}()
Why does the quine work? The above code uses several tricks.