Skip to content

Replace Cloudinary image proxy with Prismic/Imgix transforms#12

Open
erikisberg wants to merge 1 commit into
codeandconspire:masterfrom
erikisberg:cloudinary-to-prismic-imgix
Open

Replace Cloudinary image proxy with Prismic/Imgix transforms#12
erikisberg wants to merge 1 commit into
codeandconspire:masterfrom
erikisberg:cloudinary-to-prismic-imgix

Conversation

@erikisberg

Copy link
Copy Markdown

Bakgrund

Cloudinary-kontot som appen använt stängs 2026-09-01. Cloudinary användes bara som transform-proxy i fetch-läge (resize/crop/format/quality) samt för att hämta YouTube/Vimeo-posters — källbilderna ligger redan i Prismic, som servar dem via Imgix.

Ändring

  • components/base/index.js: src()/srcset() översätter Cloudinary-tokens till Imgix-query-params direkt på Prismic-URL:en (c_fillfit=crop, f_jpgfm=jpg, w/h/q). Redaktörens beskärning (rect) bevaras.
  • Embeds (serialize.js + video() i page/about/terms) använder oembed.thumbnail_url direkt.
  • Tar bort /media-proxyrouten i server.js, lib/cloudinary-proxy.js och cloudinary-beroendet.
  • README + .env.example uppdaterade.

Verifierat

  • npm run build ok, standard rent (enda kvarvarande lint-felet är pre-existerande i server.js).
  • Live-testat mot Prismic/Imgix: transformerade URL:er ger korrekt nedskalade JPEG:ar.
  • Deployat till produktion (fly.io spillosoferna, release v13) — /malen serverar nu Imgix-bilder, noll /media- eller cloudinary-referenser.

Efter merge är appen inte längre beroende av Cloudinary-kontot.

🤖 Generated with Claude Code

Cloudinary was only used as an on-the-fly transform proxy (fetch mode) and
for fetching YouTube/Vimeo posters - source images already live in Prismic,
which serves them via Imgix. Apply resize/crop/format/quality as query params
directly on the Prismic image URL instead, preserving the editorial crop
(rect). Embed posters now use the oEmbed thumbnail_url directly.

Removes the /media proxy route, lib/cloudinary-proxy.js and the cloudinary
dependency, so the app no longer depends on the Cloudinary account being
shut down on 2026-09-01.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant