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

chaitail

v1.2.2

Published

A lightweight utility first CSS framework

Readme

☕ ChaiTail

A lightweight utility-first CSS engine built with JavaScript.

ChaiTail lets you author utility classes directly in HTML and converts them into inline styles at runtime — no compiled CSS required.


What’s New

  • Massive Utility Expansion Added layout constraints, directional spacing (px, py, mt, mx-auto), typography scales (text-xl, leading-loose, tracking-wide), and advanced appearance tokens (shadow-lg, opacity-80, transition-all).

  • Advanced Flex & Grid Control Full flexbox mapping (flex-wrap, flex-col, items-center) and grid support.

  • Expanded Sizing Utilities Added chai-h-, chai-w-, chai-gap-, chai-max-w-, chai-min-h-.

  • Smart Color System Colors map through teaColors and support named colors + raw hex values.


Features

  • Zero-Build Styling Write classes like chai-p-20, chai-text-masala-chai — no CSS files needed.

  • Dynamic Class Parsing chai-p-100padding: 100px automatically.

  • Lightweight & Fast Efficient DOM scanning and instant style application.

  • Tea-Inspired Design System Custom warm color palette (masala-chai, green-tea, etc.)

  • Available as npm package https://www.npmjs.com/package/chaitail

  • No frameworks required Built using plain JavaScript.


Installation

npm install chaitail

Usage

1. Import in your project

import { initChai } from "chaitail";

initChai();

2. Use classes in HTML

<div class="chai-p-40 chai-bg-white chai-rounded-20 chai-shadow-lg chai-max-w-600 chai-mx-auto">
  <h1 class="chai-text-4xl chai-text-masala-chai chai-font-bold chai-tracking-tight">
    Hello ChaiTail!
  </h1>
  <p class="chai-text-md chai-text-dark-tea chai-leading-relaxed chai-mt-20">
    This component was styled completely without CSS files or inline style tags.
  </p>
</div>

Using with Vite (Recommended)

ChaiTail works best with modern bundlers like Vite.

1. Create a Vite project

npm create vite@latest
cd your-project
npm install

2. Install ChaiTail

npm install chaitail

3. Use in main.js

import { initChai } from "chaitail";

initChai();

4. Run project

npm run dev

How it Works

  • Scans the DOM for class names
  • Detects classes starting with chai-
  • Matches static utilities from ChaiCSS.js
  • Parses dynamic utilities (px-, bg-, max-w-, etc.)
  • Converts them into inline styles
  • Applies styles and removes chai-* classes

Supported Utilities

Layout & Sizing

  • chai-flex, chai-flex-col, chai-items-center, chai-justify-center
  • chai-mx-automargin: 0 auto
  • chai-w-full, chai-h-full, chai-max-w-1200, chai-min-w-300
  • chai-z-10, chai-relative, chai-overflow-hidden

Directional Spacing

  • chai-pt-20, chai-pb-20, chai-px-40, chai-py-40
  • chai-mt-20, chai-gap-20
  • chai-p-[val], chai-m-[val]

Typography

  • chai-text-xschai-text-6xl
  • chai-font-bold, chai-font-light
  • chai-text-center, chai-text-right
  • chai-tracking-tight, chai-tracking-wide
  • chai-leading-tight, chai-leading-relaxed
  • chai-uppercase, chai-no-underline

Color & Appearance

  • chai-bg-red, chai-bg-#ff0000, chai-bg-masala-chai
  • chai-text-white, chai-text-#fff
  • chai-opacity-60, chai-opacity-80
  • chai-shadow-md, chai-shadow-lg, chai-shadow-xl
  • chai-border-light, chai-border-dashed, chai-border-none
  • chai-rounded-[val], chai-rounded-full

Interactivity

  • chai-transition-all
  • chai-translate-y-[val], chai-translate-x-[val]
  • chai-cursor-pointer

Project Structure

chaitail/
├── src/
│   ├── index.js
│   ├── applyClass.js
│   ├── ChaiCSS.js
│   └── teaColors.js
└── package.json

Notes

  • Requires modern browsers (ES Modules support)
  • Best experience with Vite or similar bundlers
  • Plain HTML usage requires relative imports

Author

Vishal Patil


Support

If you like this project, give it a ⭐ on GitHub!