Skip to content

Instantly share code, notes, and snippets.

@shanefulmer
Created August 10, 2013 03:03
Show Gist options
  • Save shanefulmer/6198848 to your computer and use it in GitHub Desktop.
Save shanefulmer/6198848 to your computer and use it in GitHub Desktop.
Secrets of the JavaScript Ninja pg 53-54
function Ninja() {
this.skulk = function () { return this; };
}
var whatever = Ninja();
console.log(whatever);
"But the effect would be for the skulk property to be created on window, and for window to be returned and stored in whatever"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment