{"id":17647913,"url":"https://github.com/viccon/node-stream-chunker","last_synced_at":"2026-02-24T03:33:05.314Z","repository":{"id":42963988,"uuid":"225367390","full_name":"viccon/node-stream-chunker","owner":"viccon","description":"A minimal node transform stream for splitting data into chunks","archived":false,"fork":false,"pushed_at":"2023-01-05T02:07:44.000Z","size":364,"stargazers_count":4,"open_issues_count":4,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-10-13T08:40:46.904Z","etag":null,"topics":["javascript","node","node-js","nodejs"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/viccon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-12-02T12:14:33.000Z","updated_at":"2023-07-18T14:35:29.000Z","dependencies_parsed_at":"2023-02-03T05:16:09.018Z","dependency_job_id":null,"html_url":"https://github.com/viccon/node-stream-chunker","commit_stats":null,"previous_names":["charlesconner/bufferedsplitter","viccon/node-stream-chunker"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/viccon/node-stream-chunker","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/viccon%2Fnode-stream-chunker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/viccon%2Fnode-stream-chunker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/viccon%2Fnode-stream-chunker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/viccon%2Fnode-stream-chunker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/viccon","download_url":"https://codeload.github.com/viccon/node-stream-chunker/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/viccon%2Fnode-stream-chunker/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29770769,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-24T03:15:54.600Z","status":"ssl_error","status_checked_at":"2026-02-24T03:15:54.143Z","response_time":75,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["javascript","node","node-js","nodejs"],"created_at":"2024-10-23T11:14:56.492Z","updated_at":"2026-02-24T03:33:05.290Z","avatar_url":"https://github.com/viccon.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Stream chunker\nThis module implements the Node transform stream interface. It keeps an internal\nbuffer of a given size, and will spit out a chunk each time it fills up.\n\nIf you want to split a large file into chunks, based on a delimiter, you would\nbasically do this:\n\n``` javascript\nconst fs = require('fs');\nconst StreamChunker = require('./streamChunker');\nconst chunker = new StreamChunker(20, '\\n'); // The delimiter used here is \\n\nfs.createReadStream('largeDatabaseFile.csv')\n  .pipe(chunker)\n  .on('data', data =\u003e {\n    // data here will be a chunk of 20 items.\n  })\n  .on('finish', () =\u003e console.log('Stream finished.'));\n```\n\n\n## Options\nThe StreamChunker constructor takes three arguments:\n- chunkSize (number)\n- delimiter (string)\n- defaultEncoding (string, defaults to 'utf-8')\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fviccon%2Fnode-stream-chunker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fviccon%2Fnode-stream-chunker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fviccon%2Fnode-stream-chunker/lists"}