{"_id":"@1-/read","_rev":"2-89f49425363e204fdf4a2af2bb0e2e18","name":"@1-/read","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.0":{"name":"@1-/read","version":"0.1.0","keywords":["file","fs","promise","read","utf8"],"author":{"name":"x-at-01@googlegroups.com"},"license":"MulanPSL-2.0","_id":"@1-/read@0.1.0","maintainers":[{"name":"i18n-now","email":"i18n.site@gmail.com"}],"homepage":"https://github.com/webc-site/npm/tree/main/read","bugs":{"url":"https://github.com/webc-site/npm/issues"},"dist":{"shasum":"cd60f1e9310be10c8d23dddc767d909f70c4c0eb","tarball":"https://registry.npmjs.org/@1-/read/-/read-0.1.0.tgz","fileCount":3,"integrity":"sha512-0RTH1qS8r62tMPUUTGIWJKicn5KP15Dp8GY8pkI01QqguvU5koMYERrryTMnTHFMJMZmWzw+LJlMOxxM6fCdDw==","signatures":[{"sig":"MEYCIQCduMacK+Md8Ei3mLWQgMgSRnveolyx52rzPcnvyx3PrQIhAPEVSrq3goIcu2ZWm1tvrNTln9s3HWE3c0CSkkKCRlew","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":3554},"type":"module","exports":{".":"./_.js","./*":"./*"},"_npmUser":{"name":"i18n-now","email":"i18n.site@gmail.com"},"repository":{"url":"git+https://github.com/webc-site/npm.git","type":"git"},"_npmVersion":"11.13.0","description":"Read file as UTF-8 string / 读取文件为 UTF-8 字符串","directories":{},"_nodeVersion":"26.2.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/read_0.1.0_1781058746683_0.14138139144845496","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"name":"@1-/read","version":"0.1.1","description":"Read file as UTF-8 string / 读取文件为 UTF-8 字符串","keywords":["file","fs","promise","read","utf8"],"homepage":"https://github.com/webc-site/npm/tree/main/read","license":"MulanPSL-2.0","author":{"name":"x-at-01@googlegroups.com"},"repository":{"type":"git","url":"git+https://github.com/webc-site/npm.git"},"type":"module","exports":{".":"./_.js","./*":"./*"},"_id":"@1-/read@0.1.1","bugs":{"url":"https://github.com/webc-site/npm/issues"},"_nodeVersion":"26.2.0","_npmVersion":"11.16.0","dist":{"integrity":"sha512-Zz2eYvS6cQSTgOJkjEaB/4lk/0RUD8vJOhlw9nmubVT2ZqfSZmQ+YAr5XXIm75Bv375U6jsbh2BNPvzvWNvKYg==","shasum":"9fd5da76a9e4a3d49e5415862cb4591633ce92c4","tarball":"https://registry.npmjs.org/@1-/read/-/read-0.1.1.tgz","fileCount":3,"unpackedSize":3730,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCjXdndILwLfLrlYcQm+wl2iDsfs/bOQ+hckjhM6IuAvwIhAOmdxbjYPYRZzKQ2+xYi/RCJitRWFjCamMDln1UytAGd"}]},"_npmUser":{"name":"i18n-now","email":"i18n.site@gmail.com"},"directories":{},"maintainers":[{"name":"i18n-now","email":"i18n.site@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/read_0.1.1_1781144859804_0.40886673186249034"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-10T02:32:26.511Z","modified":"2026-06-11T02:27:40.082Z","0.1.0":"2026-06-10T02:32:26.826Z","0.1.1":"2026-06-11T02:27:39.943Z"},"bugs":{"url":"https://github.com/webc-site/npm/issues"},"author":{"name":"x-at-01@googlegroups.com"},"license":"MulanPSL-2.0","homepage":"https://github.com/webc-site/npm/tree/main/read","keywords":["file","fs","promise","read","utf8"],"repository":{"type":"git","url":"git+https://github.com/webc-site/npm.git"},"description":"Read file as UTF-8 string / 读取文件为 UTF-8 字符串","maintainers":[{"name":"i18n-now","email":"i18n.site@gmail.com"}],"readme":"[English](#en) | [中文](#zh)\n\n---\n\n<a id=\"en\"></a>\n# @1-/read : Read file as UTF-8 string\n\n- [@1-/read : Read file as UTF-8 string](#1-read-read-file-as-utf-8-string)\n  - [Features](#features)\n  - [Usage](#usage)\n  - [Design](#design)\n  - [Tech Stack](#tech-stack)\n  - [Code Structure](#code-structure)\n  - [History](#history)\n  - [About](#about)\n\n## Features\n\n- Reads file content asynchronously\n- Wraps Node.js `fs/promises.readFile` API\n- Returns UTF-8 decoded string\n- Minimal runtime overhead\n\n## Usage\n\n```javascript\nimport read from \"@1-/read\";\n\nconst content = await read(\"path/to/file.txt\");\nconsole.log(content);\n```\n\n## Design\n\nWraps native promise-based file system API with UTF-8 encoding as default. Input file path, output decoded string.\n\n![](https://fastly.jsdelivr.net/gh/webc-fs/-@NH/A-wUgd4iu3UFI-igVZ8w.svg)\n\n## Tech Stack\n\n- Runtime: Node.js 18+ / Bun\n- Language: JavaScript (ES Module)\n- Package format: ESM\n\n## Code Structure\n\n- `src/_.js`: Main implementation exporting default function\n- `package.json`: Package metadata and exports configuration\n- `tests/_.test.js`: Test suite\n\n## History\n\nIn 1992, Ken Thompson and Rob Pike designed UTF-8 encoding on a restaurant placemat. The encoding solved ASCII backward compatibility while enabling universal text representation. This library implements UTF-8 file reading as a minimal utility, reflecting the principle that simple interfaces enable robust systems.\n\n## About\n\nThis library is developed by [WebC.site](https://webc.site).\n\n[WebC.site](https://webc.site): A new paradigm of web development for AI\n\n\n---\n\n<a id=\"zh\"></a>\n# @1-/read : 读取文件为 UTF-8 字符串\n\n- [@1-/read : 读取文件为 UTF-8 字符串](#1-read-读取文件为-utf-8-字符串)\n  - [功能介绍](#功能介绍)\n  - [使用演示](#使用演示)\n  - [设计思路](#设计思路)\n  - [技术栈](#技术栈)\n  - [代码结构](#代码结构)\n  - [历史故事](#历史故事)\n  - [关于](#关于)\n\n## 功能介绍\n\n- 异步读取文件内容\n- 封装 Node.js `fs/promises.readFile` API\n- 返回 UTF-8 解码字符串\n- 极小运行时开销\n\n## 使用演示\n\n```javascript\nimport read from \"@1-/read\";\n\nconst content = await read(\"path/to/file.txt\");\nconsole.log(content);\n```\n\n## 设计思路\n\n封装原生 Promise 风格文件系统 API，默认使用 UTF-8 编码。输入文件路径，输出解码后字符串。\n\n![](https://fastly.jsdelivr.net/gh/webc-fs/-@f8/SuJmVVKQSow6450cxyHw.svg)\n\n## 技术栈\n\n- 运行环境：Node.js 18+ / Bun\n- 语言：JavaScript (ES Module)\n- 包格式：ESM\n\n## 代码结构\n\n- `src/_.js`: 主要实现，导出默认函数\n- `package.json`: 包元数据与导出配置\n- `tests/_.test.js`: 测试套件\n\n## 历史故事\n\n1992 年，Ken Thompson 与 Rob Pike 在餐厅餐巾纸上设计出 UTF-8 编码。该编码解决 ASCII 向后兼容性问题，同时支持统一文本表示。本库实现 UTF-8 文件读取作为轻量级工具，体现简单接口构建稳健系统的理念。\n\n## 关于\n\n本库由 [WebC.site](https://webc.site) 开发。\n\n[WebC.site](https://webc.site) : 面向人工智能的网站开发新范式\n\n","readmeFilename":"README.md"}