@name module API

Brendan Eich brendan at mozilla.com
Fri Apr 13 17:35:50 PDT 2012

Erik Arvidsson wrote:
> We should really use ''new Name'' instead of ''create''.
> import {Name} from '@name';
> let myName = new Name;
> instead of
> module name = '@name';
> let myName = name.create();

+1 from me.

> JS has dedicated syntax for creating new objects. Lets use that. There
> is also no precedence for ''create'' functions in JS. This would be
> the first one (second, considering Proxy.create but that was removed)
You ignore Object.create in ES5, but I'm hip.


More information about the es-discuss mailing list