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

@shinkofa/tokens

v0.1.0

Published

Canonical business token values (Ki, Wellness, Priority, Energy) for the Shinkofa ecosystem

Downloads

79

Readme

@shinkofa/tokens

Canonical business token values for the Shinkofa ecosystem — Ki, Wellness, Priority, Energy.

This package is the single source of truth for the values of Shinkofa's cross-cutting business vocabulary: the Ki scale and its difficulty costs, the priority levels and their ordering, the wellness dimensions and their scales, and the energy bands. Apps import these instead of re-declaring constants.

Why this package exists

The business vocabulary was scattered: copied by hand in Michi-Shinkofa, mixed with colors in @shinkofa/ui, implied in @shinkofa/types. Centralising the values here keeps @shinkofa/ui free of Shinkofa-specific business meaning so it can stay publishable as open source (NLNet), and gives every app one place to read the canonical numbers and keys.

Frontier — what goes where

| Package | Owns | Example | |---------|------|---------| | @shinkofa/tokens | Business values: scales, bounds, ordering, i18n keys | KI_SCALE = { min: 0, max: 10 }, PRIORITY_ORDER | | @shinkofa/types | TypeScript shapes: interfaces, unions | interface Task { priority: Priority } | | @shinkofa/ui | Presentation: colors, icons, components | PRIORITY_COLORS, <TaskCard> | | @shinkofa/i18n | Text: FR/EN/ES labels | wellness:ki.executive → "Exécutif" | | @shinkofa/holistic-core (planned) | Logic: budget math, derivation | calculateKiBudget() |

Rule of thumb: a number, a bound, an ordering, or an i18n key is a token → it lives here. A type lives in @shinkofa/types. A color or component lives in @shinkofa/ui. A function that computes something lives in @shinkofa/holistic-core. This package contains zero logic — values only.

Labels are NOT here

Tokens carry an i18n key per value (e.g. KI_I18N_KEYS.executive === 'wellness:ki.executive'), never the translated text. The words live in @shinkofa/i18n. This keeps value and text decoupled and trilingual.

What's inside

| Module | Exports | |--------|---------| | ki | KI_TYPES, KiType, KI_SCALE, KI_DEFAULT_LEVEL, DIFFICULTY_LEVELS, DifficultyLevel, DIFFICULTY_KI_COST, KI_I18N_KEYS | | priority | PRIORITY_LEVELS, Priority, PRIORITY_ORDER, PRIORITY_I18N_KEYS | | wellness | WELLNESS_DIMENSIONS, WellnessDimension, MEAL_QUALITY_SCALE, HYDRATION_SCALE, SPORT_INTENSITY_SCALE, SLEEP_QUALITY_SCALE, WELLNESS_SCALES, WELLNESS_I18N_KEYS | | energy | ENERGY_BANDS, EnergyBand, ENERGY_SCALE, ENERGY_DEFAULT_LEVEL, ENERGY_BAND_I18N_KEYS |

The Priority, KiType, DifficultyLevel, WellnessDimension and EnergyBand types are derived from their value arrays (as const), so the values and the type can never drift apart.

Install

"@shinkofa/tokens": "github:shinkofa/Shinkofa-Shared#main&path=packages/tokens"

Usage

import {
  KI_TYPES,
  KI_SCALE,
  DIFFICULTY_KI_COST,
  PRIORITY_LEVELS,
  PRIORITY_ORDER,
  ENERGY_BANDS,
} from '@shinkofa/tokens';

// Order tasks by canonical priority rank (never hardcode the order)
tasks.sort((a, b) => PRIORITY_ORDER[a.priority] - PRIORITY_ORDER[b.priority]);

// Clamp a check-in value to the canonical Ki scale
const level = Math.min(KI_SCALE.max, Math.max(KI_SCALE.min, raw));

// Default Ki cost for a "complex" task
const cost = DIFFICULTY_KI_COST.complex; // 4

Combine with @shinkofa/i18n to render labels:

import { KI_I18N_KEYS } from '@shinkofa/tokens';
import { useTranslation } from '@shinkofa/i18n';

const { t } = useTranslation();
const label = t(KI_I18N_KEYS.executive); // "Exécutif" / "Executive" / "Ejecutivo"

Scripts

| Command | What | |---------|------| | pnpm build | Bundle CJS + ESM + types (tsup) | | pnpm test | Run the value-invariant tests (vitest) | | pnpm type-check | tsc --noEmit (strict) |

Status

0.1.0 — initial extraction of Ki, Priority, Wellness, Energy tokens.

Consumers still holding hand-copied values (notably Michi-Shinkofa) will migrate to import from here in a dedicated pass; that migration is intentionally separate so each consumer's tests can prove parity on its own.