Re: Proposal: Map#assign

2018-01-18 Thread Gil Tayar
I believe there's a very simple way to do this today: new Map([...mapA, ...mapB, ...mapC]). Almost as nice as map.assign :-) - Gil Tayar On Thu, Jan 18, 2018 at 8:12 PM T.J. Crowder < tj.crow...@farsightsoftware.com> wrote: > On Thu, Jan 18, 2018 at 6:08 PM, Mike Samuel wrote: &

Re: import.meta and TC39 process as a whole

2017-08-04 Thread Gil Tayar
myself or about the community I surround myself with. - Gil Tayar On Fri, Aug 4, 2017 at 9:47 AM kai zhu wrote: > > > I’m curious what the concerns were. You mentioned disliking the syntax, > but I’m guessing there’s more to it than that? > > the concern is that es modules are starti

Re: Recent language addition suggestions

2017-07-18 Thread Gil Tayar
Note that the initial discussion was not about not adding features or yes adding features. It was about adding niche and convenience feature that will help only in niche situations. So, IMHO, adding features like async await that benefit everybody and change the language in a meaningful way, yes.

Re: How about awaiting Arrays ?

2017-03-04 Thread Gil Tayar
As someone who teaches JavaScript a lot, I believe that not explaining what promises are when teaching async/await is not possible, because await only works on *promises*. You need to at least understand that promises are "async values" to understand and use aysnc/await. What is abstracted away is

Re: Array Comprehensions

2017-02-06 Thread Gil Tayar
Forgive me if I'm wrong, but the double-for comprehension (e.g. [for (i of numbers) for (j of letters) i + j]) can't be easily expressed in JS because there's no flatMap. - Gil On Mon, Feb 6, 2017 at 7:17 PM T.J. Crowder wrote: > Given `Array.prototype.filter`, `Array.prototype.map`, and other

Re: NodeJS's __filename/__dirname in ES6 Modules

2017-01-21 Thread Gil Tayar
all URLs. Please use https://url.spec.whatwg.org/ which ships in Node v7+ > under `require('url').URL` and the proposal to bring it into the language > itself https://github.com/jasnell/proposal-url . Getting the "directory" > of a URL would be ~= `new URL('.',

Re: NodeJS's __filename/__dirname in ES6 Modules

2017-01-21 Thread Gil Tayar
. Getting the "directory" > of a URL would be ~= `new URL('.', file_url)`. > > On Sat, Jan 21, 2017 at 10:42 AM, Gil Tayar wrote: > > Thanks! > > Makes total sense. So why not have Domenic's "import" be a real function > that comes from thi

Re: NodeJS's __filename/__dirname in ES6 Modules

2017-01-21 Thread Gil Tayar
roup): in NodeJS's implementation of ES6 modules, how > will __dirname and __filename be implemented? Will there still be a > function wrapper like in the current module implementation? Or will > __dirname and __filename be a "syntactic form" like import()? Or something >

NodeJS's __filename/__dirname in ES6 Modules

2017-01-20 Thread Gil Tayar
and __filename be a "syntactic form" like import()? Or something else? Thanks, Gil Tayar ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: await on synchronous functions

2015-07-17 Thread Gil Tayar
_ >>> es-discuss mailing list >>> es-discuss@mozilla.org >>> https://mail.mozilla.org/listinfo/es-discuss >>> >>> >> >> ___ >> es-discuss mailing list >> es-discuss@mozilla.org >> https://mail.mozilla.org/listinfo/es-discuss >> >> > > ___ > es-discuss mailing list > es-discuss@mozilla.org > https://mail.mozilla.org/listinfo/es-discuss > > -- Yours, Gil Tayar Software Architect @ Wix ___ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss

Re: Named Paramters

2015-07-12 Thread Gil Tayar
some cases > ``` > > 2. Code with this feature will be broken after minification. > ___ > es-discuss mailing list > es-discuss@mozilla.org > https://mail.mozilla.org/listinfo/es-discuss > -- Yours, Gil Tayar Software Architect @ Wi