Created
October 24, 2009 21:56
-
-
Save rmurphey/217759 to your computer and use it in GitHub Desktop.
things i love about javascript
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var foo = [ 1, 2, 3, { a : 'b' } ]; | |
var bar = foo[foo.length-1]; | |
bar.c = 'bar'; | |
console.log(foo); // [ 1, 2, 3, { a : 'b', c : 'bar' } ] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment