Skip to content
JS
Package

flatten

Flatten arbitrarily nested arrays into a non-nested list of non-array items. Maintained for legacy compatibility.

v1.0.3, 31 Oct 2019MIT-Types: None
$ npm install flatten
Deprecated on npm
flatten is deprecated in favor of utility frameworks such as lodash.

Key numbers

As of 25 Sept 2026
Weekly downloads
3.5m
+2% over 12 months
Gzip bundle size
-
No Bundlephobia data
Dependencies
0
Direct, from package.json
Last release
6 years ago
v1.0.3
GitHub stars
5
3 forks
Open issues / PRs
4 / 0
Contributors
-
Commits, last 52 weeks
0

Downloads

Last week 2026-09-15 to 2026-09-21
01m2m3m4mSept 2025Mar 2026Sept 2026High 3.5m (25 Nov 2025)Low 1.2m (23 Dec 2025)
Weekly npm downloads, one point per week, weeks starting 23 Sept 2025 to 15 Sept 2026. The y axis starts at zero.

3,511,836 downloads last week, 11,479,214 in the last month. The 12-month change of +2% compares the average of the last 4 weeks with the first 4 weeks of the series.

Releases, last 12 months
06 in total
Latest version
1.0.3, 31 Oct 20196 years ago
First published
28 Jun 2012
Last push to GitHub
31 Oct 20192,520 days before the snapshot
Repository archived
No
Open issues
4
Open pull requests
0
Commits, last 52 weeks
0
Dependents on npm
-

Major versions

  1. v1 first release 1.0.0, 20 Jan 2016
  2. v0 first release 0.0.0, 28 Jun 2012

Recent releases

VersionPublished
1.0.331 Oct 2019
1.0.220 Jan 2016
1.0.120 Jan 2016
1.0.020 Jan 2016
0.0.128 Jun 2012
0.0.028 Jun 2012
Module format
-Not determined from package.json
TypeScript types
None
Node.js engine range
Not declared
Runtimes
-
Unpacked size (npm)
3.6 kB
Dependencies (0)
None
npm install flatten
  • jsDelivrhttps://cdn.jsdelivr.net/npm/flatten@1.0.3/
  • unpkghttps://unpkg.com/flatten@1.0.3/
  • esm.shhttps://esm.sh/flatten@1.0.3
Sources: npm registry, npm downloads API, GitHub API. Data fetched 25 Sept 2026.

Indexability: Not indexed (discovery only): deprecated; no category.