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

@4i4/starter-theme

v0.1.3

Published

Base layout theme primitives shared across @4i4 themes.

Readme

@4i4/starter-theme

Base layout theme extracted from the Moto React application. The package exposes the shared layout templates and helpers that other themes can extend.

Development

pnpm install
pnpm build

The build step emits ESM and CJS bundles under dist/ with the original module structure preserved so Next.js dynamic imports keep working.

Extending Colors in Child Themes

Child themes can import the palette helpers and build their own color tokens while still using the shared layout primitives:

import {
  buildPalettes,
  buildButtons,
  container,
  media,
  buildColumn,
} from "@4i4/starter-theme";

const breakpoints = { xs: 0, sm: 576, md: 768, lg: 992, xl: 1280 };

const palettes = {
  primary: { main: "#0057ff", text: "#ffffff" },
  secondary: { main: "#ffb400", text: "#1d1d1d" },
  accent: { main: "#6c5ce7", text: "#ffffff" },
};

const theme = {
  palettes: buildPalettes(palettes),
  media: media(breakpoints),
  container: container(breakpoints),
  column: buildColumn(12, breakpoints),
  buttons: buildButtons(["primary", "secondary", "accent"]),
};

The starter theme now sources these layout helpers from @4i4/theme-toolkit, so you can import them directly from that package if you already depend on it elsewhere.

Any palette entry can omit the darker or lighter shades and they will be derived from the main color automatically. New palette keys become available through CSS variables like var(--color-accent) and by listing them in buildButtons.

Theme Settings via _settings

@4i4/starter-theme ships its defaults (palette, breakpoints, button order, and grid) through the _settings scope. The generated theme.json already lists those modules:

{
  "settings": {
    "palette": "./settings/palette",
    "breakpoints": "./settings/breakpoints",
    "buttons": "./settings/buttons",
    "grid": "./settings/grid"
  }
}

Inside your runtime code you can hydrate the theme via useThemeSettings while keeping access to the package defaults:

import { useThemeSettings } from "@4i4/theme-registry";
import {
  starterSettingsDefaults,
  type StarterSettings,
} from "@4i4/starter-theme";

const palette = useThemeSettings<StarterSettings>(
  "palette",
  starterSettingsDefaults,
);
const breakpoints = useThemeSettings<StarterSettings>(
  "breakpoints",
  starterSettingsDefaults,
);

Child themes can override any of these entries by calling registry.set("palette", overrideObject, "_settings") before rendering. Only the overridden keys need to be provided—the hook merges them with the defaults shipped by the starter theme.