stillat/social-media-image-kit
Stillat's Social Media Image Kit helps Laravel/PHP developers generate social media share images, such as Open Graph cards and post previews, with tools for building and rendering customizable image templates.
stillat/social-media-image-kit is a Statamic addon (delivered as a Laravel package) that generates social share/Open Graph images by rendering Antlers templates and rasterizing them, typically via a headless browser dependency. v1.4.0 is a feature release with no documented breaking changes, but it materially expands the surface area we would depend on.
Architecture fit. The package slots into the presentation edge of a Statamic site: templates define image layouts, entry data supplies content, and generated files land on a Laravel filesystem disk. That is a clean fit for content-driven marketing sites where per-entry OG images are a requirement. It is a poor fit for headless/API-only deployments where Statamic's rendering layer is not resident, and for high-volume, low-latency generation paths — image synthesis is a heavy, asynchronous-by-nature operation.
Integration feasibility. Low-to-moderate. Installation is a standard Composer require plus config publish, but the real cost is environmental: a headless Chromium/Node binary, consistent fonts, sufficient memory per render, and a writable or remote disk. The v1.4.0 additions reduce custom-code burden: Augmented Entry support means templates can traverse relations and tags through Statamic's augmentation layer rather than hand-rolled lookups, and the CP "Recreate" action removes the need for a bespoke regeneration button or console command.
Technical risk.
Key questions.
Stack fit. Appropriate for a Laravel + Statamic monolith serving a public marketing or content site on a conventional PHP host with queue workers. Not appropriate for serverless PHP runtimes without a bundled Chromium layer, or for sites with thousands of entries requiring per-request generation.
Migration path. There is no prior assessment and no incumbent to displace, so this is greenfield adoption rather than migration. The practical path:
v1.4.0 on the current Statamic major (do not combine the constraint bump and the feature adoption in one step).Compatibility. Verify the installed Statamic minor against the addon's tested matrix before committing. If we are on Statamic 5, the v1.4.0 constraint change is inert and the real deliverables are augmented entries and the Recreate action. If we intend to adopt Statamic 6, sequence that as a separate, later workstream with its own regression pass.
Sequencing. (a) environment and renderer validation → (b) single-collection template proof → (c) augmented-relation template work → (d) storage/CDN and cache-invalidation wiring → (e) editor-facing Recreate action and runbook → (f) optional Statamic 6 evaluation. Each step is independently reversible; the addon is additive and can be removed without data migration since it produces derived assets only.
Maintenance. The package is a thin addon over Statamic's rendering and augmentation APIs, so maintenance cost tracks Statamic major releases more than the addon's own churn. Budget a review per Statamic major and per quarterly addon release. Because the release cadence is low and contributor base narrow, pin versions and review changelogs rather than tracking dev-main.
Support. Expect community/maintainer support only. Internal ownership should sit with the web platform team, who must be able to diagnose a failed render from logs alone. A short internal runbook covering "image missing/malformed" triage is a prerequisite, not a nice-to-have.
Scaling. Generation is CPU- and memory-bound, dominated by the headless browser. It must run asynchronously: generate on entry publish/save via queued jobs, never inline in the editorial request. Size queue workers separately from web workers, cap concurrency to avoid memory exhaustion, and pre-warm the browser or accept cold-start latency. Serve generated images from a CDN-backed disk; the read path should never touch the generator. Volume that matters is edits, not page views — cache aggressively.
Failure modes. Silent visual regressions from the augmentation change (wrong or empty relation data rendered into an image); render timeouts and OOM under concurrent queue load; missing fonts producing fallback glyphs; stale images when entries change without triggering regeneration; disk/CDN misconfiguration producing 404s in social previews that are only visible via external validators; and constraint drift if Statamic 6 is adopted without a regression pass. Note that OG image failures are invisible to normal QA — they surface only when a link is shared, so add an automated check that recent entries resolve to a 200 image URL.
Ramp-up. Developer ramp-up is roughly one to two days for a Laravel-fluent engineer familiar with Statamic Antlers, plus half a day of infrastructure work for the Chromium/font provisioning. Editorial ramp-up is minimal — the CP Recreate action is the only new surface most editors will touch, and it should be covered in a single short walkthrough. The main knowledge concentration risk is the renderer environment; document it explicitly so it is not held by one person.
How can I help you explore Laravel packages today?