2 ms·
If I were to run the code Object.prototype.d = 4; I'd be asking for trouble.
by jvickers 12y ago
If I were to run the code
Object.prototype.d = 4;
I'd be asking for trouble.
- shawnz 12y agoI agree, but lots of JS developers (mistakenly) think there is nothing wrong with this: Object.prototype.myDumbShim = function () { ... }; Chances are good that your code will be running in the same scope as one of these people's code eventually.