Re:Treating JavaScript like a 30 year old language
by petercooper on Thursday July 05, 2012 @09:31PM
(#4205941)
It does but there are other ways to create objects (even using prototypal inheritance) in JavaScript that are pretty popular in the wild (Object.create and object literals with {} for example). The code behind this and the constructors, etc, would need to be rather different though (that is, you're right, you can't just drop new and expect it to work as-is.)
[ Parent
| on HN ]
There are no comments on this comment yet.