modules proposal

Kevin Curtis kevinc1846 at gmail.com
Sun May 16 21:15:12 PDT 2010


On Mon, May 17, 2010 at 3:27 AM, David Herman <dherman at mozilla.com> wrote:
> This makes it very convenient to reflect them as first-class values:
>
>    var x = Math;
>    alert(x["sum"]); // function(x,y) { ... }
>    alert(x["thisIsNotDefined"]); // undefined
>

Whats the difference between:
var x = Math; // or: const x = Math;

And:
module x = Math;

Thanks.
--


More information about the es-discuss mailing list