forever components

Cosmic & Space

Pulsar Lighthouse Sweep

A neutron star spins twin teal lighthouse beams that sweep and blip brighter when crossing the line of sight; dipole field lines and starfield pulse in sync.

canvasmedium complexitymoderate motionpointer

Open on the canvas to copy the code → Free account · 3 copies a day · membership goes unlimited

Live demo — the real component, running in a sandbox. One self-contained HTML file, zero dependencies. Open it on the canvas →
Worth keeping? Votes steer what gets built next — sign in to cast one, free to read

When to use it

Dark sci-fi hero backgrounds, space/astronomy themes, ambient screensaver-style tiles where metronomic rhythm adds atmosphere.

When not to

Light-background UIs (background hardcoded dark navy). Contexts where flashing blips may distract from foreground content.

Working with an AI agent

Every component ships agent-ready metadata. An example instruction for this one:

Change the spin period to 1.2 seconds by setting PERIOD=1.2, shift beam color to magenta by replacing rgba(94,255,196,...) with rgba(255,80,200,...), and increase star count from 90 to 150.

Safe to edit

  • spin period (PERIOD=2.05)
  • beam half-angle (HALF=0.30)
  • magnetic axis tilt (TILT=-0.42)
  • beam/star color (teal rgba palette)
  • star count (90)

Keep intact

  • DPR-aware canvas sizing
  • visibilitychange pause/resume
  • prefers-reduced-motion static fallback
  • IIFE wrapper

Known limitations

  • Background color hardcoded in CSS (#040810) — must edit both CSS and fillRect call to change
  • Pointer and click only add speed nudge, not directional control
  • No aria labeling on canvas

pulsarspacecanvasbeamlighthouseambientcosmic

More Cosmic & Space components

  • Orbiting Planet SystemFour glowing planets orbit a radiant sun on tilted elliptical rings with depth-sorted rendering; the system drifts subtly toward the pointer.
  • Black-hole Accretion Swirl110 heat-colored particles spiral inward across a tilted accretion disk toward a glowing event horizon; pointer movement boosts swirl speed.
  • Twinkling Starfield115 multicolor stars twinkle via sine waves; sparkle crosses appear on larger stars; stars brighten near cursor. Static fallback for reduced-motion.
  • Spiral Galaxy Rotate115 stars form a two-armed spiral galaxy rotating around a violet radial-gradient core; pointer move briefly doubles spin speed.
  • Comet Streak LoopCyan and violet comets with glowing heads and gradient tails streak diagonally across a twinkling dark starfield; click spawns an extra comet (up to 5).
  • Ringed Planet RotateAmber gas giant with tilted Saturn-like rings slowly rotates over a twinkling starfield; pointermove adjusts ring tilt and light angle dynamically.