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

@cnojs/http

v1.1.0

Published

Low-level HTTP protocol library for cno server

Readme

@cnojs/http

http/ is the low-level HTTP protocol package used by the cno runtime. It is published as @cnojs/http and is imported by Web API, Deno, and Node HTTP polyfills where raw protocol helpers are needed.

This package should stay independent from Web API objects such as Request, Response, Headers, and URL. Higher layers translate those objects into the raw shapes used here.

Exports

The package exports TypeScript source files directly:

@cnojs/http
@cnojs/http/socket
@cnojs/http/dns-cache
@cnojs/http/zlib
@cnojs/http/protocol
@cnojs/http/h1
@cnojs/http/ext-h2
@cnojs/http/server
@cnojs/http/debug
@cnojs/http/process

Directory Layout

| Path | Role | | --- | --- | | src/index.ts | Main package barrel | | src/socket.ts | TCP/TLS socket wrapper over circu.js native modules | | src/dns-cache.ts | DNS cache helper | | src/zlib.ts | Compression helpers | | src/protocol.ts | Protocol interfaces and raw message types | | src/h1.ts | HTTP/1.x builder/parser/protocol implementation | | src/server.ts | Protocol-aware server helpers | | src/debug.ts | Debug logging utilities | | src/process.ts | Progress display helpers | | ext-h2/ | HTTP/2 native extension declarations and glue | | types/ | Native module declarations used by this package |

Design Boundary

Use this package for:

  • raw bytes
  • sockets
  • protocol messages
  • HTTP/1 parsing/building
  • protocol abstractions
  • optional HTTP/2 extension types

Do not put Web API, Deno, or Node compatibility behavior here. Those belong in ../cno/src/webapi, ../cno/src/deno, or ../cno/src/node.

Build And Use

The root build consumes this package through workspace-style imports and bundles the TypeScript into the final CLI:

pnpm run type-check
cmake --build build

The package itself has no separate runtime binary. It depends on circu.js native modules being available through import.meta.use() when executed inside the cno runtime.

HTTP/2

HTTP/2 support is provided by the optional native extension under ext-h2/. The root build can statically embed it with:

cmake -B build -DCNO_EMBED_EXT_H2=ON

When not embedded, HTTP/2-specific consumers must arrange for the extension to be available through the runtime extension loading path.