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

@upft/cli

v0.0.6

Published

CLI for UPFT design token processing

Downloads

11

Readme

@upft/cli

Command-line interface for DTCG-style design token operations.

Installation

npm install -g @upft/cli
# or
pnpm add -g @upft/cli

Commands

| Command | Purpose | |---------|---------| | validate | Validate token files or manifests | | bundle | Generate token bundles from manifests | | preview | Preview token resolution with modifiers | | list | List tokens with filtering options | | diff | Compare token files or permutations | | lint | Check tokens for style and conventions | | info | Show manifest information | | permutations | List available permutations |

Usage Examples

Validation

# Validate a token file
upft validate tokens.json -f

# Validate directory of token files
upft validate ./tokens -d

# Validate manifest
upft validate manifest.json -m

Bundling

# Bundle from manifest
upft bundle manifest.json

# Bundle with custom output
upft bundle manifest.json --output dist/

# Bundle specific permutation
upft bundle manifest.json --modifiers theme=dark,density=compact

Preview & Analysis

# Preview token resolution
upft preview manifest.json --modifiers theme=light

# Preview with JSON output
upft preview manifest.json --json

# List all tokens
upft list tokens.json

# List specific type
upft list tokens.json --type color

# Show manifest info
upft info manifest.json

Comparison

# Compare two token files
upft diff tokens-v1.json tokens-v2.json

# Compare manifest permutations
upft diff manifest.json -m --left-modifiers theme=light --right-modifiers theme=dark

Linting

# Lint token files
upft lint tokens.json

# Lint manifest
upft lint manifest.json -m

# Lint with specific rules
upft lint tokens/ --rules naming,structure

Command Options

Global Options

| Option | Description | |--------|-------------| | --help | Show command help | | --version | Show version | | --verbose | Verbose output | | --quiet | Suppress output |

Validation Options

| Option | Description | |--------|-------------| | -f, --file | Validate single file | | -d, --directory | Validate directory | | -m, --manifest | Validate manifest | | --schema | Custom schema URL |

Bundle Options

| Option | Description | |--------|-------------| | --output <dir> | Output directory | | --modifiers <mod> | Modifier values (key=value,key=value) | | --resolve-refs | Resolve token references | | --minify | Minify output |

Preview Options

| Option | Description | |--------|-------------| | --modifiers <mod> | Preview with modifiers | | --json | JSON output format | | --format <fmt> | Output format (json, yaml, css) |

Configuration

Create .upftrc.json for project configuration:

{
  "validation": {
    "strict": true,
    "schemas": {
      "tokens": "https://tokens.unpunny.fun/schemas/latest/tokens/base.schema.json"
    }
  },
  "bundling": {
    "resolveReferences": true,
    "outputFormat": "json",
    "minify": false
  },
  "linting": {
    "rules": ["naming", "structure", "consistency"]
  }
}

Exit Codes

| Code | Meaning | |------|---------| | 0 | Success | | 1 | Validation errors | | 2 | File not found | | 3 | Invalid arguments | | 4 | Build/bundle errors |

Examples

Basic Workflow

# 1. Validate your tokens
upft validate tokens/ -d

# 2. Preview resolution
upft preview manifest.json --modifiers theme=light

# 3. Generate bundles
upft bundle manifest.json

# 4. Lint for consistency
upft lint tokens/ -d

CI/CD Integration

#!/bin/bash
set -e

# Validate all tokens
upft validate tokens/ -d

# Lint for style
upft lint tokens/ -d

# Generate production bundles
upft bundle manifest.json --output dist/ --minify

echo "✅ Token build successful"

Advanced Usage

# Compare design system versions
upft diff v1/tokens.json v2/tokens.json > changes.diff

# Generate all permutations
upft permutations manifest.json --json > permutations.json

# Validate with custom schema
upft validate tokens.json --schema ./custom.schema.json

Integration

Works seamlessly with:

  • @upft/foundation: Core token types and operations
  • @upft/loader: Multi-pass loading and resolution
  • @upft/bundler: Token bundling
  • @upft/validator: Schema validation
  • @upft/analysis: Token analysis and comparison
  • @upft/ast: Token AST operations
  • @upft/linter: Style checking
  • @upft/schemas: DTCG schemas
  • Design tools: Figma, Sketch token plugins
  • Build systems: Webpack, Vite, Rollup