caolan / caolan/highland

Extend batch to take a function parameter

Open
#162 9 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
JavaScript
Stars
3.4k
Forks
145
PR merge metrics
No merged PRs in 30d

Description

An extension of `batch` with a function parameter that's used to determine when to push out the current batch, rather than pushing it out every `n` elements.

The idea comes from this split-related example:
https://github.com/caolan/highland/issues/6#issuecomment-44143123

Contributor guide

Open the contributing guide

Research direction

Start by locating Highland's implementation and tests for `batch`, then read the linked split-related example for the intended behavior. Define how the function parameter determines when the current batch is emitted, and update the relevant tests so the new behavior and existing fixed-size batching are covered.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.