{"id":19113728,"url":"https://github.com/spiffgreen/flat-arr","last_synced_at":"2026-06-02T03:30:14.929Z","repository":{"id":114585695,"uuid":"390168915","full_name":"SpiffGreen/flat-arr","owner":"SpiffGreen","description":"Flatten an array of arrays into one or more. It flexible enough that you can dictate the maximum depth it unveils.","archived":false,"fork":false,"pushed_at":"2021-07-28T01:02:43.000Z","size":3,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-03T05:41:23.718Z","etag":null,"topics":["array","flatten-array","recursive-algorithm"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SpiffGreen.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-07-28T00:56:56.000Z","updated_at":"2023-03-18T11:40:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"93f800bf-95c4-4366-b9b9-94f5eb913685","html_url":"https://github.com/SpiffGreen/flat-arr","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpiffGreen%2Fflat-arr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpiffGreen%2Fflat-arr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpiffGreen%2Fflat-arr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpiffGreen%2Fflat-arr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SpiffGreen","download_url":"https://codeload.github.com/SpiffGreen/flat-arr/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240170064,"owners_count":19759143,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["array","flatten-array","recursive-algorithm"],"created_at":"2024-11-09T04:37:58.261Z","updated_at":"2026-06-02T03:30:14.829Z","avatar_url":"https://github.com/SpiffGreen.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Flat Array\nFlatten an array of arrays into one or more. It flexible enough that you can dictate the maximum depth it unveils.\n\n### Installation\nIn using npm in your project, run:\n```sh\n$ npm install flat-arr --save\n```\n\nInclude the module to use\n```js\nconst flatArr = require(\"flat-arr\");\n```\n\n### Example\n```js\nconst arr = [\n    [1, 2, 3],\n    [4, 5, 6],\n    7, 8, 9,\n    [10, \n        [11,\n            [12,\n                [13, 14, 15]\n            ],\n        16,\n        ],\n        17,\n    ],\n    18\n];\n\nconsole.log(flatArr(arr, 3));\n// [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, [ 13, 14, 15 ], 16, 17, 18 ]\n\nconsole.log(flatArr(arr));\n/* [\n   1,  2,  3,  4,  5,  6,  7,\n   8,  9, 10, 11, 12, 13, 14,\n  15, 16, 17, 18\n] */\n```\n\n### Manual Release Steps\n* Increment the \"version\" attribute of package.json\n* Commit with the message \"Release version x.x.x\"\n* Create version tag in git\n* Create a github release\n* Release on npm\n\n### Author\nSpiff Jekey-Green\n\n### License\n[MIT](./LICENSE) License","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspiffgreen%2Fflat-arr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspiffgreen%2Fflat-arr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspiffgreen%2Fflat-arr/lists"}