# @datastream/core 中文文档

规范地址：https://npmcn.com/package/%40datastream/core/

版本：0\.9\.2
npm 元数据更新时间：2026-10-24T16:04:19.965Z
中文译文更新时间：2026-11-11T15:08:51.271Z
软件包许可：MIT

本文由上游 README 翻译，可能存在偏差，请结合原文核对 API、命令与配置。版权与许可归原作者所有。

原始 npm 页面：https://www.npmjs.com/package/%40datastream/core
原文对照：https://npmcn.com/package/%40datastream/core/?lang=original
项目主页：https://datastream.js.org/
源码仓库：https://github.com/willfarrell/datastream

## 关键信息（来自 npm 元数据）

- 包体积（解压后）：100 kB，11 个文件
- 模块格式：ES Module
- TypeScript 类型：包内自带
- Node.js 要求：\>=26
- 运行依赖：0 个
- 首次发布：2022-07-24T21:24:32.291Z
- 最新版本发布：2026-10-24T16:04:19.189Z
- 近 30 天下载量：727227（2026-10-12 至 2026-11-10，npm 官方下载统计）
- 已发布版本数：54（近 12 个月 13 个）

## 中文简介

Web Streams API和Node.js流的流创建公用事业和管道功能

## 安装

```sh
npm install @datastream/core
```

也可以使用：`pnpm add @datastream/core`、`yarn add @datastream/core`、`bun add @datastream/core`

## README

# < 数据流 > “ 核心”

![datastream logo](https://raw.githubusercontent.com/willfarrell/datastream/main/websites/datastream.js.org/static/img/datastream-logo.svg)

**数据流框架的核心组件,强大的JavaScript流工具.**

[![GitHub Actions unit test status](https://github.com/willfarrell/datastream/actions/workflows/test-unit.yml/badge.svg)](https://github.com/willfarrell/datastream/actions/workflows/test-unit.yml) [![GitHub Actions dast test status](https://github.com/willfarrell/datastream/actions/workflows/test-dast.yml/badge.svg)](https://github.com/willfarrell/datastream/actions/workflows/test-dast.yml) [![GitHub Actions perf test status](https://github.com/willfarrell/datastream/actions/workflows/test-bench.yml/badge.svg)](https://github.com/willfarrell/datastream/actions/workflows/test-bench.yml) [![GitHub Actions SAST test status](https://github.com/willfarrell/datastream/actions/workflows/test-sast.yml/badge.svg)](https://github.com/willfarrell/datastream/actions/workflows/test-sast.yml) [![GitHub Actions lint test status](https://github.com/willfarrell/datastream/actions/workflows/test-lint.yml/badge.svg)](https://github.com/willfarrell/datastream/actions/workflows/test-lint.yml)  
[![npm version](https://img.shields.io/npm/v/@datastream/core.svg)](https://www.npmjs.com/package/@datastream/core) [![npm install size](https://packagephobia.com/badge?p=@datastream/core)](https://packagephobia.com/result?p=@datastream/core) [![npm weekly downloads](https://img.shields.io/npm/dw/@datastream/core.svg)](https://www.npmjs.com/package/@datastream/core) [![npm provenance](https://img.shields.io/badge/provenance-Yes-brightgreen)](https://www.npmjs.com/package/@datastream/core#provenance)  
[![Open Source Security Foundation (OpenSSF) Scorecard](https://api.scorecard.dev/projects/github.com/willfarrell/datastream/badge)](https://scorecard.dev/viewer/?uri=github.com/willfarrell/datastream) [![SLSA 3](https://slsa.dev/images/gh-badge-level3.svg)](https://slsa.dev/) [![](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](https://github.com/willfarrell/datastream/blob/main/.github/CODE_OF_CONDUCT.md) [![Checked with Biome](https://img.shields.io/badge/Checked_with-Biome-60a5fa?style=flat&logo=biome)](https://biomejs.dev/) [![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-%23FE5196?logo=conventionalcommits&logoColor=white)](https://conventionalcommits.org/) [![code coverage](https://img.shields.io/badge/code%20coverage-100%25-brightgreen)](https://github.com/willfarrell/datastream/blob/main/package.json#L22)

您可以在下列地方阅读文档: [https://datastream.js.org 页面存档备份,存于互联网档案馆](https://datastream.js.org/)

## 安装

要安装数据流,您可以使用国家防范机制:

```bash
npm install --save @datastream/core
```

## 文件和实例

关于文件和实例,参见主要文件: [gitHub 上的数据流单列波](https://github.com/willfarrell/datastream) 或者说 [数据流官方网站](https://datastream.js.org/)。 。 。 .

## 捐款

我们非常欢迎每个人为这个存放处作出贡献。 随便你 [提出问题](https://github.com/willfarrell/datastream/issues) 或改为 [提交拉动请求](https://github.com/willfarrell/datastream/pulls)。 。 。 .

## 许可证

许可证根据 [MIT 许可证](https://github.com/willfarrell/datastream/blob/main/LICENSE)版权(c) 2026 [将法瑞尔](https://github.com/willfarrell),以及 [数据流贡献者](https://github.com/willfarrell/datastream/graphs/contributors)。 。 。 .

## 常见问题

### @datastream/core 是什么？

Web Streams API和Node\.js流的流创建公用事业和管道功能

### 如何安装 @datastream/core？

在项目目录运行 npm install @datastream/core，或使用 pnpm add / yarn add / bun add。

### @datastream/core 支持 TypeScript 吗？

支持。包内自带 TypeScript 类型声明（package\.json 声明了 types 入口），安装后即可获得类型提示，无需再安装 @types 包。

### @datastream/core 支持 ESM 还是 CommonJS？

以 ES Module 形式发布，推荐使用 import 引入。在 CommonJS 项目中，Node\.js 20\.19\+ / 22\.12\+ 可以直接 require\(\) 不含顶层 await 的 ES Module，更早的版本需要改用动态 import\(\)。

### @datastream/core 需要什么版本的 Node\.js？

package\.json 的 engines 字段要求 Node\.js \>=26。版本不符时 npm 默认只给出警告，开启 engine-strict 后会拒绝安装。

### @datastream/core 可以商用吗？

@datastream/core 使用 MIT 许可。宽松许可：允许商业使用、修改和再分发，通常只需在分发时保留原版权与许可声明。以上为概括，不构成法律意见，请以许可原文为准。

### @datastream/core 的下载量有多少？

根据 npm 官方下载统计，@datastream/core 在 2026/10/12 – 2026/11/10 这 30 天内被下载 727,227 次，日均约 24,241 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入，适合横向比较热度，不能直接等同于使用人数。

### @datastream/core 还在维护吗？

最新版本 0\.9\.2 发布于 2026/10/25（18 天前）；至今共发布 54 个版本，其中过去 12 个月发布了 13 个；首次发布于 2022/07/25。发布频率只是参考信号：功能稳定的工具可能很少需要更新，建议结合源码仓库的 issue 和提交记录判断。

