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

yashrajnayak-design-system

v0.1.0

Published

Reusable design system extracted from yashrajnayak.github.io

Readme

Yash Design System

Reusable design system extracted from yashrajnayak.github.io, packaged as a standalone repo so you can reuse the same visual language across future projects.

What this includes

  • Design tokens (color, typography, spacing, radius, shadows, motion)
  • Dark mode support via data-theme="dark"
  • Reusable CSS components (cards, glass cards, buttons, pills, badges, lists, accordion, layout helpers)
  • Utility classes for spacing, stacks, text, and flex clusters
  • Demo documentation site in docs/

Project structure

design-system/
  src/
    tokens.css
    base.css
    animations.css
    components.css
    utilities.css
    themes.css
    index.css
  dist/
    yashrajnayak-design-system.css
    yashrajnayak-design-system.min.css
  docs/
    index.html
    docs.css
    docs.js
  scripts/
    build.sh

Quick start

npm run build
npm run dev
  • Build output: dist/yashrajnayak-design-system.css
  • Docs preview: http://localhost:4173

Use in another project

Option 1: copy CSS directly

<link rel="stylesheet" href="/path/to/yashrajnayak-design-system.css">

Option 2: install from npm (after publish)

npm install yashrajnayak-design-system
import 'yashrajnayak-design-system/dist/yashrajnayak-design-system.css';

Required fonts

<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700&display=swap" rel="stylesheet">

Theme toggle pattern

Set theme by changing the data-theme attribute on <html>:

document.documentElement.setAttribute('data-theme', 'dark');

Supported values:

  • light (default)
  • dark

Using this in future projects

  1. Install the package:
npm install yashrajnayak-design-system
  1. Load required fonts once in your app shell (index.html, app/layout.tsx, etc.):
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700&display=swap" rel="stylesheet">
  1. Import the design system stylesheet once near app startup:
import 'yashrajnayak-design-system/dist/yashrajnayak-design-system.css';
  1. Use ys- classes for components and utilities, and use --ys-* variables for custom styles.

  2. Use theme switching by setting data-theme on <html>:

document.documentElement.setAttribute('data-theme', 'dark');

Migrating existing projects to this design system

Use an incremental migration, not a full rewrite.

  1. Install and import the design system, while keeping your current CSS.
  2. Start migrating shared primitives first: buttons, cards, headings/text styles, and spacing/layout wrappers.
  3. Migrate one screen/section at a time to reduce regressions.
  4. Remove old component CSS only after that section visually matches and passes smoke checks.

If your app has old token names, add a temporary bridge in your app CSS:

:root {
  --old-primary: var(--ys-color-primary);
  --old-surface: var(--ys-color-surface);
  --old-text: var(--ys-color-text);
}

Updating all apps when the design system changes

Release workflow for this repo

  1. Update design system code.
  2. Bump version in package.json (patch, minor, or major).
  3. Build and publish:
npm run build
npm publish --access public

Consumer app strategy

  1. Pin a compatible major version in each app, for example:
"dependencies": {
  "yashrajnayak-design-system": "^1.2.0"
}
  1. Enable dependency update PRs (Dependabot or Renovate) in every app repo so each new release opens an update PR automatically.

Sample Dependabot config:

version: 2
updates:
  - package-ecosystem: "npm"
    directory: "/"
    schedule:
      interval: "weekly"
    open-pull-requests-limit: 10
  1. Merge update PRs after a quick visual smoke test.

Manual multi-repo update (optional)

If you want to update local repos in bulk:

for repo in ~/Documents/GitHub/*; do
  if [ -f "$repo/package.json" ] && rg -q "\"yashrajnayak-design-system\"" "$repo/package.json"; then
    (cd "$repo" && npm install yashrajnayak-design-system@latest)
  fi
done

Publish as a GitHub repo

git remote add origin [email protected]:yashrajnayak/design-system.git
git branch -M main
git add .
git commit -m "Initial design system"
git push -u origin main

Publish to npm

Before publishing, ensure the package name in package.json is available.

npm login
npm publish --access public

Versioning recommendation

  • patch: small non-breaking fixes
  • minor: new components or utility classes
  • major: breaking token or class name changes