{"id":22458271,"url":"https://github.com/ksm2/isomorphic-streams","last_synced_at":"2025-07-04T10:05:55.498Z","repository":{"id":45265398,"uuid":"432296668","full_name":"ksm2/isomorphic-streams","owner":"ksm2","description":"Isomorphic WHATWG Streams API package for browser and Node.js","archived":false,"fork":false,"pushed_at":"2022-09-07T14:56:41.000Z","size":96,"stargazers_count":14,"open_issues_count":3,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-09T09:02:58.991Z","etag":null,"topics":["isomorphic-javascript","web-streams","whatwg-streams"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/ksm2.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-11-26T20:43:24.000Z","updated_at":"2023-10-23T09:30:07.000Z","dependencies_parsed_at":"2022-09-07T17:24:03.653Z","dependency_job_id":null,"html_url":"https://github.com/ksm2/isomorphic-streams","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/ksm2/isomorphic-streams","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ksm2%2Fisomorphic-streams","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ksm2%2Fisomorphic-streams/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ksm2%2Fisomorphic-streams/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ksm2%2Fisomorphic-streams/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ksm2","download_url":"https://codeload.github.com/ksm2/isomorphic-streams/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ksm2%2Fisomorphic-streams/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260907158,"owners_count":23080612,"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":["isomorphic-javascript","web-streams","whatwg-streams"],"created_at":"2024-12-06T08:11:50.180Z","updated_at":"2025-07-04T10:05:55.463Z","avatar_url":"https://github.com/ksm2.png","language":"TypeScript","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"readme":"# isomorphic-streams\n\n[![Node.js CI](https://github.com/ksm2/isomorphic-streams/actions/workflows/node.js.yml/badge.svg)](https://github.com/ksm2/isomorphic-streams/actions/workflows/node.js.yml)\n[![NPM version](https://img.shields.io/npm/v/isomorphic-streams)](https://www.npmjs.com/package/isomorphic-streams)\n[![license](https://img.shields.io/github/license/ksm2/isomorphic-streams)](https://opensource.org/licenses/MIT)\n[![TypeScript types](https://img.shields.io/npm/types/isomorphic-streams)](https://github.com/ksm2/isomorphic-streams/blob/main/index.d.ts)\n\n\u003e Isomorphic [WHATWG Streams API] package for browser and Node.js\n\nThis package has\n\n- **zero dependencies**\n- provides **TypeScript typings**\n- supports `ReadableStream`, `WritableStream` and `TransformStream`\n\n## Table of Contents\n\n- [Install](#install)\n- [Usage](#usage)\n- [Contributing](#contributing)\n- [License](#license)\n\n## Install\n\nUse either\n\n    yarn add isomorphic-streams\n\nor\n\n    npm install isomorphic-streams\n\n## Usage\n\n**In the browser:** Instead of using the global `ReadbaleStream` or `window.ReadableStream`, import from this package instead.\n\n**In Node.js:** Instead of importing `node:stream/web` or requiring `stream/web`, import from this package instead.\n\nThe following code will work in both Node.js and the browser:\n\n```js\nimport { ReadableStream } from \"isomorphic-streams\";\n\nconst SECOND = 1000;\n\nconst stream = new ReadableStream({\n  start(controller) {\n    setInterval(() =\u003e {\n      controller.enqueue(Date.now());\n    }, SECOND);\n  },\n});\n\nfor await (const value of stream) {\n  console.log(value);\n}\n```\n\n[More examples][examples]\n\n## Contributing\n\nThis project is open to feedback and contributions, please open an issue.\n\n`isomorphic-streams` follows the [Contributor Covenant] Code of Conduct.\n\n## License\n\nMIT © 2021 Konstantin Möllers, see [LICENSE].\n\n[whatwg streams api]: https://streams.spec.whatwg.org/\n[license]: https://github.com/ksm2/isomorphic-streams/blob/main/LICENSE\n[contributor covenant]: https://github.com/ksm2/isomorphic-streams/blob/main/CODE_OF_CONDUCT.md\n[examples]: https://github.com/ksm2/isomorphic-streams/tree/main/examples\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fksm2%2Fisomorphic-streams","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fksm2%2Fisomorphic-streams","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fksm2%2Fisomorphic-streams/lists"}