mongez-reinforcements-arrays

Provide typed array helpers for chunking, deduplication, grouping, and statistics.

3|2|Updated Dec 20, 2021
One-click install
npx skills add https://github.com/hassanzohdy/reinforcements --skill mongez-reinforcements-arrays
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: mongez-reinforcements-arrays
Source: https://github.com/hassanzohdy/reinforcements/tree/main/skills/arrays
Command: npx skills add https://github.com/hassanzohdy/reinforcements --skill mongez-reinforcements-arrays

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides a compact set of typed, dependency-free array helpers to perform common data transformations without pulling in large libraries.

Core Features & Use Cases

  • Chunk and range operations for partitioning data.
  • Deduplication, projection (pluck), and grouping (groupBy, countBy) across arrays.
  • Basic statistics (sum, average, median, min, max) and parity filtering (even/odd) on values or object properties.
  • Mutating helpers (pushUnique/unshiftUnique) to safely grow arrays without duplicates.

Quick Start

Use the arrays skill to chunk and dedupe a dataset, group items by a key, and compute basic statistics in one pass.

Frequently Asked Questions about mongez-reinforcements-arrays

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I chunk and group array data without adding heavy dependencies?

Use lightweight, typed array helpers that require zero runtime dependencies to perform common array transformations like chunking and grouping without pulling in large utility libraries.

What is the best way to pluck nested values from an array of objects?

The best way to pluck nested values is by using array helpers with dot-notation path support, allowing you to safely extract and project specific properties from deeply nested objects in an array.

Can I compute basic statistics like sum and median on array values?

Yes, you can compute basic statistics including sum, average, median, min, and max directly on array values or by targeting specific object properties within the dataset.

Does this array transformation approach work for both frontend and backend workflows?

Yes, these typed array helpers are designed to support common data transformations across both frontend and backend workflows without requiring any runtime dependencies.

How do I safely push items to an array while preventing duplicates?

Use mutating helpers like pushUnique and unshiftUnique to safely grow arrays without duplicates, ensuring your dataset remains deduplicated during insertion operations.