Skip to content

Save base64 logo images as files with jsDelivr URLs#18

Merged
williamw merged 2 commits intomasterfrom
MKT-88-save-images
Mar 17, 2026
Merged

Save base64 logo images as files with jsDelivr URLs#18
williamw merged 2 commits intomasterfrom
MKT-88-save-images

Conversation

@williamw
Copy link
Contributor

  • Converts base64 data URI logo_url values to image files served via jsDelivr, so Webflow CMS can consume all model logos as public URLs
  • Updates CI workflow to commit data/images/ alongside models.json

Notes

  • Only affects models whose logo_url is a data URI (currently 2 of 35). Models with regular URLs are unchanged.
  • Images directory is cleared and recreated each run to prevent stale files from accumulating.
  • jsDelivr caches @master for up to 24h, which is acceptable given the daily cron schedule and rarity of logo changes.

Changes

Script

File Change
scripts/fetch-models.js Updated — add parseDataUri helper, base64 image extraction, jsDelivr URL replacement

CI

File Change
.github/workflows/fetch-models.yml Updated — add data/images/ to git add

Config

File Change
.gitignore Updated — ignore docs/ dir

- Detect data URI logo_url values and decode to data/images/
- Replace with public jsDelivr CDN URLs for Webflow CMS consumption
- Clear and recreate images dir each run to remove stale files
- Update CI workflow to commit data/images/ alongside models.json
- Gitignore docs/ directory
@williamw williamw self-assigned this Mar 17, 2026
@williamw williamw marked this pull request as ready for review March 17, 2026 17:13
@williamw williamw merged commit 39534f3 into master Mar 17, 2026
@williamw williamw deleted the MKT-88-save-images branch March 17, 2026 17:17
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