Skip to content

Instantly share code, notes, and snippets.

@royletron
Created October 25, 2016 12:42
Show Gist options
  • Save royletron/0bfac66057f5a3c9a7b01e4aa973d5ed to your computer and use it in GitHub Desktop.
Save royletron/0bfac66057f5a3c9a7b01e4aa973d5ed to your computer and use it in GitHub Desktop.
'use strict';
NaN = 0 // Syntax error!
var obj1 = {};
Object.defineProperty(obj1, 'x', {value: 10, writeable: false});
obj1.x = 9 // Syntax error!
var obj2 = {x: 10};
obj2.x = 20; // Accepted
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment