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

@chenpu17/serve-here

v1.0.2

Published

A minimal CLI to serve static files from a directory over HTTP.

Readme

serve-here

Serve any local directory over HTTP with a single command.
用一条命令把任意本地目录通过 HTTP 暴露出去。

Features | 功能特点

  • Instant static hosting for the current or specified directory.
    立即托管当前目录或指定目录。
  • Automatic index.html support plus clean directory listings.
    自动识别 index.html,无首页时提供整洁的目录列表。
  • Safe redirects for non-ASCII directory names (e.g. 中文路径).
    支持中文等非 ASCII 路径的安全重定向。
  • Directory rows include file size and last modified time.
    列表项展示文件大小与最近修改时间。
  • Works as a global install or npx one-off.
    支持全局安装或通过 npx 临时使用。

Installation | 安装

npm install -g @chenpu17/serve-here

Or run it ad‑hoc without installing globally:
或者临时使用:

npx @chenpu17/serve-here

Usage | 使用方式

serve-here [options] [directory]
  • Installed globally, invoke via serve-here; with npx, run npx @chenpu17/serve-here.
    全局安装后直接使用 serve-here;临时使用时运行 npx @chenpu17/serve-here

  • directory: Directory to share; defaults to the current working directory.
    directory:要共享的目录,默认使用当前工作目录。

  • -d, --dir <path>: Explicit directory override.
    -d, --dir <path>:显式指定要共享的目录。

  • -p, --port <number>: Port to listen on (default 8080).
    -p, --port <number>:设置监听端口(默认 8080)。

  • -H, --host <address>: Host/IP to bind (default 0.0.0.0).
    -H, --host <address>:指定绑定的主机或 IP(默认 0.0.0.0)。

  • -h, --help: Show help.
    -h, --help:查看帮助信息。

  • -V, --version: Print version.
    -V, --version:查看版本号。

After startup you’ll see the bound addresses in the terminal. Opening them in a browser displays your static files or a table view of the directory contents.
启动后终端会打印可访问的地址,浏览器打开即可查看静态文件;若目录中没有 index.html,将显示带有文件大小和修改时间的目录表格。

Development | 开发

npm install
npm start

npm start serves the current project directory so you can test quickly with a browser or curl.
npm start 会把当前项目目录作为静态资源根目录,方便通过浏览器或 curl 快速验证。