sindresorhus

simplify-ranges

Merge and normalize adjacent or overlapping integer ranges

by sindresorhus

JavaScript

JavaScript100%

Commit activity

Last 12 weeks · 0 commits

Full graph →

Community health

4 of 6 standards met

Community profile →
71
✓README✓License✓Contributing✓Code of Conduct○Issue Template○PR Template
faizanu94

This PR introduces a small optimization which eliminates the creation of multiple intermediate arrays by replacing the loop with a function to accumulate the normalized and merged ranges, which results in improved performance and memory efficiency - specially for larger datasets jsPerf Benchmark: https://jsperf.app/sexite/1/preview Original: Optimized:

faizanu94 · 2y ago
Structured data for AI agents

Repository: sindresorhus/simplify-ranges. Description: Merge and normalize adjacent or overlapping integer ranges Stars: 33, Forks: 2. Primary language: JavaScript. Languages: JavaScript (100%). License: MIT. Latest release: v1.0.0 (2y ago). Open PRs: 0, open issues: 0. Last activity: 2y ago. Community health: 71%. Top contributors: sindresorhus, TomerAberbach.