On Sun, Oct 19, 2014 at 2:23 PM, Allen Wirfs-Brock <al...@wirfs-brock.com>
wrote:
>
>
> It is implementation dependent how it is determined whether an individual
> file will be parsed as a Script or as a Module.
>
> Axel alluded to a possible HTML extension that could be used to
> distinguish modules from scripts.  But, exactly how modules will be
> integrated into HTML is still under development.
>
> You can imagine various ways that modules might be identified in a command
> line environment. for example
>
> js script1.js -m mod1.js -m mod2.js script2.js
>
> so of us have argued that a module file extension might be useful in such
> environments:
>
> js script1.js mod1.js mod2.js script2.js
>

FWIW, traceur has to use --script vs --module on the command line and
.module.js among files otherwise parsed as script.

You may recall that Yehuda Katz suggested on this group that a prefix might
be used, script:file.js. To avoid long arguments about What Is a URL, I
suggest a postfix string, file.js,script. Of course a file extension would
be better. Many build tools use filenames and this issue puts practical
work with ES6 at a disadvantage.

jjb
_______________________________________________
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to