Richard Scarrott

Frontend Web Developer, London

@richardscarrott
richardscarrott pushed to ratelimit in richardscarrott/streaming-iterables 3 hours ago
1 commit to ratelimit
@richardscarrott
richardscarrott pushed to ratelimit in richardscarrott/streaming-iterables 3 hours ago
1 commit to ratelimit
@richardscarrott
richardscarrott pushed to ratelimit in richardscarrott/streaming-iterables 3 hours ago
1 commit to ratelimit
@richardscarrott

@techiemac we were able to move to telepresence 2 I'm afraid.

@richardscarrott

⚛️ A fantastically simple tagging component for your React projects v7

TypeScript 1 Updated Jan 27

@richardscarrott
richardscarrott pushed to ratelimit in richardscarrott/streaming-iterables 2 days ago
2 commits to ratelimit
@richardscarrott
richardscarrott opened a pull request in reconbot/streaming-iterables 2 days ago
+2,959 -11
@richardscarrott

A Swiss army knife for async iterables. Designed to replace your streams.

TypeScript 38 Updated Jan 27

@richardscarrott

A Swiss army knife for async iterables. Designed to replace your streams.

TypeScript 38 Updated Jan 27

@richardscarrott

For reference Highland (yeah, I'm basically copy pasting their stuff over at this rate 😅) as a ratelimit function which behaves the same way. NOTE…

@richardscarrott
richardscarrott opened an issue in reconbot/streaming-iterables 2 days ago
Throttle / rateLimit #240

Hi @reconbot I wondered if you'd considered adding a throttle utility which would yield values at a given rate. e.g. function* numbers(max: number) {

@richardscarrott

Hi @wanchaiS I'm migrating from AC2 -> AC3 and running into some of the same concerns. I'm currently generating a list of "mergeable" types with th…

@richardscarrott

We've just upgraded from AC2 -> 3 (finally!) and we're seeing this still. No other module has this issue 🤔 We're using eval source maps.

@richardscarrott
richardscarrott commented on pull request reconbot/streaming-iterables#235 9 days ago

I just noticed the docs for batch say "size can be between 1 and Infinity" so I've documented the batchWithTimeout in the same way; I guess that wa…

@richardscarrott
richardscarrott commented on pull request reconbot/streaming-iterables#235 10 days ago

@reconbot this felt like the most intuitive behaviour however it's different to the regular batch function which I think returns a single batch like

@richardscarrott
richardscarrott commented on pull request reconbot/streaming-iterables#235 10 days ago

I'm not entirely sure why this changed so drastically; I installed sinon (to allow me to mock timers) using npm 8.1.0 🤷‍♂️

@richardscarrott
richardscarrott commented on pull request reconbot/streaming-iterables#235 10 days ago

It actually does; it'll only use _batchWithTimeout if it's an async iterator and the timeout isn't Infinity, otherwise it'll just ignore timeout an…

@richardscarrott
richardscarrott commented on pull request reconbot/streaming-iterables#235 10 days ago

I explicitly check for Infinity here as setTimeout(() => {}, Infinity) is treated as 1ms which is quite unintuitive.