npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@1-/read

v0.1.1

Published

Read file as UTF-8 string / 读取文件为 UTF-8 字符串

Readme

English | 中文


@1-/read : Read file as UTF-8 string

Features

  • Reads file content asynchronously
  • Wraps Node.js fs/promises.readFile API
  • Returns UTF-8 decoded string
  • Minimal runtime overhead

Usage

import read from "@1-/read";

const content = await read("path/to/file.txt");
console.log(content);

Design

Wraps native promise-based file system API with UTF-8 encoding as default. Input file path, output decoded string.

Tech Stack

  • Runtime: Node.js 18+ / Bun
  • Language: JavaScript (ES Module)
  • Package format: ESM

Code Structure

  • src/_.js: Main implementation exporting default function
  • package.json: Package metadata and exports configuration
  • tests/_.test.js: Test suite

History

In 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.

About

This library is developed by WebC.site.

WebC.site: A new paradigm of web development for AI


@1-/read : 读取文件为 UTF-8 字符串

功能介绍

  • 异步读取文件内容
  • 封装 Node.js fs/promises.readFile API
  • 返回 UTF-8 解码字符串
  • 极小运行时开销

使用演示

import read from "@1-/read";

const content = await read("path/to/file.txt");
console.log(content);

设计思路

封装原生 Promise 风格文件系统 API,默认使用 UTF-8 编码。输入文件路径,输出解码后字符串。

技术栈

  • 运行环境:Node.js 18+ / Bun
  • 语言:JavaScript (ES Module)
  • 包格式:ESM

代码结构

  • src/_.js: 主要实现,导出默认函数
  • package.json: 包元数据与导出配置
  • tests/_.test.js: 测试套件

历史故事

1992 年,Ken Thompson 与 Rob Pike 在餐厅餐巾纸上设计出 UTF-8 编码。该编码解决 ASCII 向后兼容性问题,同时支持统一文本表示。本库实现 UTF-8 文件读取作为轻量级工具,体现简单接口构建稳健系统的理念。

关于

本库由 WebC.site 开发。

WebC.site : 面向人工智能的网站开发新范式