last day (171 days later) » 

@BenjaminGruenbaum has yield await foo() been considered?
@AwalGarg did you see the async iterators proposa?
nope, reading now
@AwalGarg goo.gl/nNLGcN
Basically, it's a generator whose next returns a promise for the next value. Like an observable but much lazier. When multiple values are concerned there are big differences between push and pull semantics.
Really cool stuff - the classic intro is: channel9.msdn.com/Events/Lang-NEXT/Lang-NEXT-2014/… from a year and a half ago
@BenjaminGruenbaum I see that much clearly now. I have entirely the same feelings as this comment: github.com/zenparsing/async-iteration/issues/…. Conditionally unwrapping based on a type check on consumer side is a good idea as well.
11:01
The good idea in term of soundness would have probably been to never automatically unwrap to begin with and make people only yield promises. That would have confused developers though who just want "async to work"
:27992073 You're asking why you'd want metastreams?
They actually have a lot of use cases - anything that combines streams really.
@BenjaminGruenbaum and what things combine streams?
flatMap, merge, all their friends
For example: I map a url to a stream of its data, and I want to have streams of all the requests (but not start them), then I want to start them conditionally (after a filter) and then merge their subscriptions.
With promises it's easier, but that's not really a fair comparison because promises are already started actions - for example to start everything at once.
@BenjaminGruenbaum Right, but I can't see any use cases to do that in userland code. Since people are used to .then of Promise objects being a flatMap as well, it seems people also want streams to auto flatmap
@BenjaminGruenbaum oh, hmm, right
@AwalGarg I actually just wrote code that does that in the JS room for madara
wait no, as a comment.
Observable.from(arr).map(requestWithPromise).flatMap(actuallyWait)
Although I think people overuse observables a lot :D
@BenjaminGruenbaum I think the url example makes sense only for cold observables though, not hot ones :D
but yeah, valid point
11:08
Yes, for hot ones it doesn't make sense.
11:29
@BenjaminGruenbaum this is awesome
 
1 hour later…
12:50
@BenjaminGruenbaum With the funny shirt, right?
 
1 hour later…
The old room can serve as a tombstone :P
room topic changed to ECMAScript: For high level discussion of the ECMAScript language. Spec discussion, discussion of libraries you're contributing to, high level stuff - welcome. Support questions are not. [ecmascript]
room topic changed to ECMAScript: For high level discussion of the ECMAScript language. Spec discussion, discussion of libraries you're contributing to, high level stuff - welcome. Support questions are not. [ecmascript] [es-2015] [es-2016]
If you are a JS room regular and would like to be invited - feel free to request access.
room mode changed to Gallery: anyone may enter, but only approved users can talk
feels similar now
14:22
Yup
I wonder how come bundling isn't a solved problem yet.
HTTP2 is taking forever, and seems rather impractical for a small team.
@BenjaminGruenbaum How do webpack and co fall short?
@MadaraUchiha it just feels a lot harder to work with than the olden times. It's like builds are a few generations back.
@MadaraUchiha needlessly complicated for most of the cases.
oh btw, I hacked a small bundler recently myself. it worked surprisingly well
And the fact that writing one was easier than using webpack is something worrying :(
Yup, but it really is a hard problem (builds)
And oh so easy to get wrong due to caching issues
Webpack 2 is supposed to be pretty good
@BenjaminGruenbaum why does it seem impractical for a small team?
14:26
@AwalGarg because performance typically ends up being slower than http/1.1 with off the shelf solutions.
You'd expect something like webpack for http2 push on the backend and bundling to go away altogether.
@BenjaminGruenbaum by off the shelf solutions you mean current implementations in servers and browsers? I haven't benchmarked myself but cloudflare guys say it is working well for them and those using cloudflare
cloudflare is exactly the sort of big company that can make it work.
yeah, but what about people using cloudflare as a front-agent (they offer it to even the free tier users)
Well, at TipRanks - we noticed slowdowns when we tried it
It might have just been misconfigured though
server?
14:33
Both when it was proxying php and when it was proxying iis
I have tested nginx 1.9.5 mainline for 5 megs of data transfer split between 30+ files (images, css, js) all gzipped with ssl. It wasn't observably faster than the equivalent HTTP1 setup, but devtools and logs did indicate speedups
(It is nowhere near a real world test though. just refreshed a couple of times and collected logs)
14:55
@MadaraUchiha in stackoverflow.com/a/34706771/1348195 you might want to aggregate errors. Other than that it mostly looks good - I might execute it in a Promise.resolve to convert throws to rejections
const retry = retries => fn => retries? fn().catch(retry(retries-1).bind(null, fn)) : fn();
That could be more elegant, hmm
Well, with async functions for sure.
Hi
Anyone played with SIMD.js?
16:57
3
Q: Is there any benefit to call Reflect.apply() over Function.prototype.apply() in ECMAScript 2015?

madox2I am just wondering if there is any good reason to call: Reflect.apply(myFunction, myObject, args); instead of: myFunction.apply(myObject, args);

I've been doing some consulting for an Angular 1 project and I MISS ARROW FUNCTIONS
@copy you still working on the honeypot?
Oh god yeah.
It's so frustrating to work on old not-transpiled code.
How's NG2's tooling coming along btw?
shrug
aside from that bit of consulting, haven't done frontend in months
At work, most of what I do just runs latest Node, so I don't even need to transpile
17:57
Don't you miss destructuring?
yes but that's not nearly as big of a deal
Gustav's been progressing as well, doing a lot of dogfooding at work: github.com/SomeKittens/gustav
18:39
Awesome - used at work too?
 
3 hours later…
22:08
@SomeKittens Currently working on emulator, but it's running
I can't wait for web assembly to ship. I want to write a JIT from x86 to web assembly
 
1 hour later…
23:34
@BenjaminGruenbaum Yeah, next generation of our map
@copy Emulator? How so?
Trying to get Windows, ReactOS, *BSD running
inside the honeypot? Nice
Huh? No, this is unrelated to the honeypot
This project: github.com/copy/v86
23:51
oh, that
cool

  last day (171 days later) »