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

@gum-jsx/mark

v2.0.0

Published

Markdown to terminal rendering with embedded Gum figures and math.

Readme

@gum-jsx/mark

Markdown-to-terminal rendering for Gum. It renders ANSI-styled text with fenced gum code blocks, local PNG/JSX images, and TeX math displayed through the kitty graphics protocol.

See the Gum project for getting started and the package overview.

Command line

npm install -g @gum-jsx/mark

gum-mark notes.md -t light -H 100
gum-mark notes.md -p
printf 'Hello $x^2$\n' | gum-mark

The bundled gum-mark executable (also available as gumd) runs under Node.js 24+ or Bun 1.4.2+. It includes the Markdown parser, Gum renderer, fonts, and PNG WebAssembly. The package retains its source library exports and their dependencies. Omit the file or use - to read stdin. The terminal must support the kitty graphics protocol; pager mode also needs Unicode placeholder support and less -R.

Code block options width=, height=, and theme= override the command-wide settings. Image alt text accepts the same options, such as ![height=300](figure.png).

# A short note

Inline math: $e^{i\pi}+1=0$.

```gum width=320 theme=light
<Frame padding={em(1)}>
  <Text>Hello, Gum</Text>
</Frame>
```

Local image paths resolve from the process's working directory. Gum fences and JSX images execute JavaScript through the evaluator; render trusted documents.

Library usage

The source library API requires Bun or a compatible TypeScript bundler.

import { displayMarkdown } from '@gum-jsx/mark'

const markdown = '# Hello\n\nInline math: $x^2$'
process.stdout.write(displayMarkdown(markdown, { theme: 'light', width: 800 }))

displayMarkdown(content, options?) returns a string containing ANSI text and kitty image sequences. Gum figures and math use @gum-jsx/png and tiny-skia WebAssembly without native addons or install scripts. Live text, emoji without outlines, and external SVG images are unsupported. Use PNG or JSX images. Local PNGs are sent directly to the terminal.

| Option | Meaning | | --- | --- | | theme | Figure and math palette: light or dark. | | width | Maximum figure/image width in pixels. | | imageHeight | Maximum figure/image height; default 500 pixels. | | height | Display-math render height. | | inlineHeight | Inline-math render height. | | scope | Additional bindings for evaluated Gum source. | | cell | Terminal cell size in pixels, for image placement. | | virtual | Image transmission callback and cell geometry for placeholder output. |

queryCellSize() and readStdin() are also exported. The CLI handles terminal queries and pager setup; run gum-mark --help for its options and defaults.

Development

From this package directory:

bun run build
bun run test
bun run typecheck

build writes the Node-compatible CLI and bundled assets/licenses to dist/npm/. npm pack and npm publish invoke it through prepack.

Tests exercise the source CLI and the packed executable under Node and Bun.