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

@retro-crt/solid

v1.0.0

Published

Solid adapter for retro-crt

Readme

retro-crt

A CRT monitor effect your content renders inside. Curvature, bloom and chromatic aberration apply to the real pixels of whatever you wrap, not a scanline sticker on top.

Zero runtime dependencies. 9.3 KB gzipped.

Install

npm install retro-crt                      # plain JS
npm install retro-crt @retro-crt/react     # or /vue, /svelte, /solid, /angular

Use it

import { CRT } from 'retro-crt'
import 'retro-crt/styles.css'

const screen = CRT.mount('#app', { curvature: 0.4 })

screen.update({ curvature: 0.7 })
screen.activeRenderer // 'webgl' | 'svg' | 'css'
screen.destroy()
import { CRTScreen } from '@retro-crt/react'
import 'retro-crt/styles.css'

<CRTScreen curvature={0.4} scanlines={{ intensity: 0.6 }}>
  <App />
</CRTScreen>

Every adapter takes the same plain CRTOptions object. All adapters are SSR-safe. To wrap a whole page, call CRT.mountFullPage().

Wrapping content breaks position: fixed inside it. A CSS filter makes its element the containing block for every fixed descendant. Use CRT.mountFullPage() for a whole page, which the spec exempts.

Renderers

renderer: 'auto' picks one of three tiers from measured facts, never the user-agent string.

| | webgl | svg | css | |---|---|---|---| | Curvature | true barrel | approximation | edge shading | | Chromatic aberration | yes | yes | no | | Persistence | yes | no | no | | Content stays interactive | no | yes | yes | | Picked for | a lone image, video or canvas | Chrome and Firefox on desktop | Safari over animating content, low-end devices |

The WebGL tier is a separate chunk that loads only when something uses it.

Options

interface CRTOptions {
  renderer?: 'auto' | 'webgl' | 'svg' | 'css'        // 'auto'
  background?: string                                // '#000000'
  curvature?: number                                 // 0-1, 0.3
  vignette?: number                                  // 0-1, 0.5
  scanlines?: { intensity?: number; gap?: number; flicker?: boolean }   // 0.5, 3px, false
  tint?: { preset?: 'default' | 'green' | 'amber' | 'blue' | 'violet' | 'lime' | 'pink' | 'red'
           strength?: number }                       // 'default', 0.35
  bloom?: { enabled?: boolean; radius?: number; strength?: number; threshold?: number }
  chromaticAberration?: { intensity?: number }       // 0-6px, 0.6
  noise?: { enabled?: boolean; static?: number }     // true, 0.04
  persistence?: { strength?: number }                // 0-0.5, 0 (webgl only)
  bezel?: { enabled?: boolean; thickness?: number; radius?: { outer?: number; screen?: number }
            color?: string; bevel?: number; lightAngle?: number; innerLip?: number
            screenSpill?: number; glare?: number; shadow?: boolean }
  quality?: 'auto' | 'high' | 'balanced' | 'low'     // 'auto'
  maxPixelRatio?: number                             // 2
  pauseWhenOffscreen?: boolean                       // true
  respectReducedMotion?: boolean                     // true
  respectSaveData?: boolean                          // true
}

Out-of-range numbers clamp. Unknown values fall back to the default. background and bezel.color accept #rgb, #rrggbb and rgb() only. When a renderer cannot honour an option you set, it ignores it and warns once in development.

prefers-reduced-motion stops flicker, grain and persistence. prefers-reduced-transparency halves tint and bloom. Save-Data forces the CSS tier. Effect layers are aria-hidden and pointer-events: none.

License

MIT