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

@stellardeck/core

v0.10.1

Published

StellarDeck engine: Deckset-compatible markdown parser, autoflow layout inference, deck health diagnostics.

Readme

@stellardeck/core

Engine for StellarDeck — a markdown presentation tool. This package contains the parser, autoflow layout inference, deck health diagnostics, and shared constants. Pure JS, no DOM, no Node-only modules: runs in Node 22+, browsers, and Web Workers.

Currently private. The package will be published once the surface stabilises and the VS Code extension consuming it ships.

Status

  • API stability: internal, expected to change before 1.0.
  • Test coverage: 511 unit tests across host shell + 33 contract / drift / pure-rule tests local to the package.
  • Render parity: validated by the StellarDeck app (Electron), browser viewer, embed playground, and CLI exporter — all four consume this package.

Layout

src/
  index.js              CJS public API barrel
  index.mjs             ESM barrel (re-exports index.js named keys)
  types.d.ts            Hand-written type definitions
  autoflow.js           Layout inference rules (declarative)
  deckset-parser.js     Deckset markdown → <section> HTML
  diagnostics.js        DOM-bound deck health checks
  diagnose-rules.js     Pure rules (snapshot → warnings, no DOM)
  constants.js          THEMES registry, slide dims, CDN URLs
  print-mode.js         Browser-only: enter/exit print/export mode
  browser-globals.js    Bundle entry — registers window.* globals
dist/
  browser-globals.global.js   Built IIFE (loaded via <script>)

Public API

const {
  // Autoflow
  applyAutoflow, createAutoflowContext, AUTOFLOW_DEFAULTS,
  RULES, SKIP_CHECKS, LAYOUT_MODIFIERS, POSITIONS,

  // Parser
  parseDecksetMarkdown, parseSlide,
  findMedia, isMediaOnly, isVideo, isAudio, parseYouTube,
  extractDirectives, extractNotes,
  DIRECTIVE_REGISTRY, FRONTMATTER_NAMES, isFrontmatterLine,
  sectionAttrsFromDirectives,

  // Diagnostics
  mergeDiagnostics, groupDiagnostics,

  // Constants
  CDN, SLIDE, THEMES,
} = require('@stellardeck/core');

ESM consumers use the same names:

import { parseDecksetMarkdown, applyAutoflow, THEMES } from '@stellardeck/core';

Subpath imports

When you only need one slice of the engine, import the module directly to keep the surface narrow:

| Subpath | What it exports | | ------------------------------------ | -------------------------------------------------- | | @stellardeck/core/autoflow | applyAutoflow, createContext, RULES, … | | @stellardeck/core/parser | parseDecksetMarkdown, parseSlide, media helpers | | @stellardeck/core/diagnostics | DOM-bound diagnoseSlide + merge / groupWarnings | | @stellardeck/core/diagnose-rules | Pure rules: runPureRules, statementDegradedRule, … | | @stellardeck/core/constants | CDN, SLIDE, THEMES | | @stellardeck/core/print-mode | Browser print/export mode (enter / exit) |

Browser usage (script tag)

For HTML pages without a bundler:

<script src="@stellardeck/core/dist/browser-globals.global.js"></script>
<script>
  const html = window.parseDecksetMarkdown(myMarkdown);
  // window.applyAutoflow, window.StellarConstants.THEMES, etc.
</script>

The bundle registers six globals: applyAutoflow, createAutoflowContext, parseDecksetMarkdown, StellarConstants, StellarDiagnostics, StellarPrintMode. It is built via npm run build (tsup → IIFE).

Web compat

Pure-JS path (parser, autoflow, diagnose-rules, constants) avoids:

  • document, window, getComputedStyle, getBoundingClientRect
  • fs, path, child_process, os, native modules

DOM-bound modules (diagnostics.js, print-mode.js) only run when a browser context exists; in Node they are still requireable but their DOM-touching functions will throw if invoked.

Building

npm install            # workspaces hoist tsup, dist is built via prepare hook
npm run build          # tsup → dist/browser-globals.global.js

The CJS / ESM source under src/ is consumed directly without a build step — only the IIFE bundle needs tsup.

License

MIT — same as the parent StellarDeck repo.