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

@cawalch/porchlight

v0.10.0

Published

A no-dependency, native-CSS framework for building accessible, themeable web applications.

Downloads

1,929

Readme

@cawalch/porchlight

Porchlight is a no-dependency, native-CSS framework for accessible, themeable web applications. See the root README and the docs site for full guidance.

Install

pnpm add @cawalch/porchlight
# or
npm install @cawalch/porchlight

Full Bundle

The main export is a prebuilt stylesheet: one file, no @import statements for your bundler to resolve.

@layer porchlight, app;
@import "@cawalch/porchlight";

@layer app {
  /* your product styles */
}

Smaller Bundles

If your app only uses a few components, start with core.css, then import the pieces you need.

@layer porchlight, app;

@import "@cawalch/porchlight/core.css";
@import "@cawalch/porchlight/layout.css";
@import "@cawalch/porchlight/components/button.css";
@import "@cawalch/porchlight/components/field.css";
@import "@cawalch/porchlight/components/card.css";
@import "@cawalch/porchlight/utilities.css";

core.css includes layer order, reset, tokens, themes, and base styles. Component files depend on those tokens, so load core.css first.

If you want the whole practical framework without experimental enhancement syntax, use compat.css. It includes core, layout, all components, and utilities, but leaves out enhancements.css.

@layer porchlight, app;
@import "@cawalch/porchlight/compat.css";

Static HTML

For server-rendered apps or pipelines that copy assets directly, use the included copy helper:

npx porchlight copy --out public/porchlight --compat

For a smaller static slice, name the components you use:

npx porchlight copy --out public/porchlight --components button,field --layout --utilities
<link rel="stylesheet" href="/porchlight/core.css" />
<link rel="stylesheet" href="/porchlight/components/button.css" />
<link rel="stylesheet" href="/porchlight/components/field.css" />
<link rel="stylesheet" href="/app.css" />

In app.css, declare your layer order before writing overrides:

@layer porchlight, app;

@layer app {
  /* app overrides */
}

The generated dist/porchlight.manifest.json lists every packaged CSS file, component name, and recommended copy order for scripts.

Vite

Vite handles CSS @import and modern CSS syntax well, so either the full bundle or selected component imports work.

@layer porchlight, app;
@import "@cawalch/porchlight/core.css";
@import "@cawalch/porchlight/components/button.css";
@import "@cawalch/porchlight/components/data-table.css";
@import "@cawalch/porchlight/utilities.css";

You can also import CSS from your JS/TS entry when that is more convenient:

import "@cawalch/porchlight/core.css";
import "@cawalch/porchlight/components/button.css";
import "./app.css";

Bun And Other Static Pipelines

Bun 1.3.14 can bundle compat.css and selected component imports. It may print non-fatal warnings for @property.

@layer porchlight, app;
@import "@cawalch/porchlight/compat.css";
@layer porchlight, app;
@import "@cawalch/porchlight/core.css";
@import "@cawalch/porchlight/components/button.css";

The full default bundle and enhancements.css include @container scroll-state(...), which Bun 1.3.14 does not parse. If you need those enhancement rules, bypass CSS parsing and copy the prebuilt files to static assets instead:

bun x porchlight copy --out public/porchlight --full

That path is also the best fit for Go, Rails, Django, and other server-rendered apps that serve CSS through a static file handler.

Tokens

Porchlight ships generated token metadata for editor autocomplete, validation, and custom tooling.

import tokenDoc, { tokenGroups } from "@cawalch/porchlight/tokens";

console.log(tokenDoc.tokens["--pl-color-accent"].value);
console.log(tokenGroups.map((group) => group.name));

JSON is available too:

import tokens from "@cawalch/porchlight/tokens.json";

Exports

| Import path | What you get | | ------------------------------------------- | ---------------------------------------- | | @cawalch/porchlight | Full prebuilt CSS bundle | | @cawalch/porchlight/min.css | Minified full bundle | | @cawalch/porchlight/compat.css | Bun-friendly bundle without enhancements | | @cawalch/porchlight/core.css | Layer order, reset, tokens, themes, base | | @cawalch/porchlight/layout.css | Layout primitives | | @cawalch/porchlight/components.css | All component CSS | | @cawalch/porchlight/components/button.css | One component CSS file | | @cawalch/porchlight/utilities.css | Utility classes | | @cawalch/porchlight/enhancements.css | Progressive enhancement layer | | @cawalch/porchlight/tokens | Typed token metadata module | | @cawalch/porchlight/tokens.json | Token metadata JSON | | @cawalch/porchlight/manifest.json | Static-copy manifest | | @cawalch/porchlight/src/* | Raw source escape hatch |

Layer Ordering

Porchlight wraps every rule in @layer porchlight.*. Declare your app layer after Porchlight so product CSS wins without specificity fights.

Do not pass layer(...) to these imports. Porchlight already self-layers.

Browser Support

Targets Chrome/Edge 149+, Safari 18+, Firefox 135+. Porchlight uses modern CSS including @layer, @scope, @property, OKLCH, light-dark(), color-mix(), :has(), container queries, Popover API, and anchor positioning. See the Browser Support guide for the full feature matrix.