``` import fs; import "fs"; ``` too confusing :/
> On Jan 26, 2016, at 12:59 PM, Paul Tyng <[email protected]> wrote: > > Yeah, its definitely limited in its scope as to which modules it applies to, > but thats not necessarily a bad thing, i guess a side effect could be that it > pushes more people towards underscore vs dash in module naming. > > We don't need a shorthand on object literals either, but we do. Having the > redundant text does increase the likelihood of a typo, but not by much. > > This doesn't (in theory at least) impact any existing code, and I imagine > would be fairly simplistic in implementation. Famous last words I guess. > > On Tue, Jan 26, 2016 at 3:52 PM /#!/JoePea <[email protected] > <mailto:[email protected]>> wrote: > So this is only valid with modules that have a valid JavaScript identifier as > their name. I think it could be nice in the cases where the identifier > matches a module name. I don't have an argument against it, and would use it > if it existed, though I can live without it. > > /#!/JoePea > > On Jan 26, 2016 12:45 PM, "Paul Tyng" <[email protected] > <mailto:[email protected]>> wrote: > No it does not compete with the string literal version (see my proposal, no > quotes), its an identifier only. 3d-is-cool is not a valid identifier so > couldn't work, neither would es6-shim. > > On Tue, Jan 26, 2016 at 3:44 PM Jordan Harband <[email protected] > <mailto:[email protected]>> wrote: > also, would identifier would `import '3d-is-cool';` create? > > On Tue, Jan 26, 2016 at 12:43 PM, Jordan Harband <[email protected] > <mailto:[email protected]>> wrote: > That is currently valid syntax for a module that has no exports - ie, a > module for which you're relying solely on side effects. One popular usage is > `import 'es6-shim';` for example. > > On Tue, Jan 26, 2016 at 12:31 PM, Paul Tyng <[email protected] > <mailto:[email protected]>> wrote: > I went through the archives and existing proposals, I didn't see one similar > to this. I apologize if its been covered before. I thought that redundant > import statements could be simplified with a shorthand that works similar to > object literal notation. > > import fs; > > vs > > import fs from 'fs'; > > https://github.com/paultyng/proposal-shorthand-import > <https://github.com/paultyng/proposal-shorthand-import> > > I would welcome any feedback. > > Thanks, > Paul Tyng > > _______________________________________________ > es-discuss mailing list > [email protected] <mailto:[email protected]> > https://mail.mozilla.org/listinfo/es-discuss > <https://mail.mozilla.org/listinfo/es-discuss> > > > > > _______________________________________________ > es-discuss mailing list > [email protected] <mailto:[email protected]> > https://mail.mozilla.org/listinfo/es-discuss > <https://mail.mozilla.org/listinfo/es-discuss> > > _______________________________________________ > es-discuss mailing list > [email protected] > https://mail.mozilla.org/listinfo/es-discuss
_______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

