Urgent.News

What's breaking now, across thousands of outlets.

Tech

Turning one TypeScript CardSpec into 49 static palette PNGs

Belle AI (aicoloranalysis.io) publishes downloadable color-palette cards: one for each of the twelve sub-seasons and four parent seasons, plus cards for 20 celebrity pages and 13 "color analysis for …" audience pages. All 49 come from one CardSpec shape and one React layout, and each has a fixed .png URL. This post walks through how that is wired and what I checked on the live site. The code is…

Belle AI provides downloadable color-palette cards for twelve sub-seasons, four parent seasons, twenty celebrity pages, and thirteen audience pages. All 49 cards are generated from a single CardSpec shape and a React layout, with each card having a fixed .png URL. The code was sourced from a specific commit on 2026-11-04. The color palette data for seasons and special pages is stored in separate files, while all cards share a common shape defined in palette-card-spec.ts.

This shape is parsed by a renderer function that understands it, producing four builder functions for seasons, celebrities, and audience pages. The filenames follow a specific pattern, separating season slugs, parent seasons, celebrity slugs, and attribute slugs. A route handler generates static parameters for all 49 cards, turning them into PNG responses served with optimized headers for caching.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

Single-Run Lab Audits of 96 Local Business Sites: What the Numbers Actually Say

In March 2026 I ran a PageSpeed Insights API audit on 96 Ottawa-area service business websites: plumbers, electricians, HVAC companies, cleaners, contractors.

  • Median mobile PageSpeed score was 65.5 out of 100 for 96 Ottawa businesses.
  • 10 sites scored between 90-100, 67 between 50-89, and 19 below 50.
  • Overall mobile score improved to 71.0 median after November 3, 2026 audit.

Making a calculator other sites can embed, on a fully static site

I run a small site for freelancers, Paid & Filed , and its most useful page is a free 1099 tax calculator that works out quarterly estimated tax.

  • Calculator embedded via React component
  • Embed route excludes header, footer, analytics
  • Height adjustment script for seamless display

Implement Training File Export with Temporary Downloads (Presigned URLs, Retention)

The constraint that changes this design is large-file throughput. An education platform should keep export bytes off its application workers, issue a short-lived download URL only after authorization…

  • Implement export as immutable object with signed GET request URL.
  • Record timestamps and policy selection for reproducible audits.
  • Use storage service for large data path, API for control-plane job.

More from Sunday 15 November →