Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Php Respimg

Php Respimg Laravel Package

nwtn/php-respimg

nwtn/php-respimg is a PHP library for responsive image handling: generate resized image variants, build srcset and sizes markup, and serve appropriately sized images across devices with simple configuration for PHP applications.

View on GitHub
Deep Wiki
Context7

A responsive image workflow for optimizing and resizing your images

Frequently asked questions about Php Respimg
What does nwtn/php-respimg do for responsive images in Laravel?
It generates multiple resized image variants from one source file and outputs ready-to-use srcset or picture markup. In Laravel, use it as a build-time or queued image pipeline behind your own adapter, not as a request-time resizing service. It is framework-agnostic, so Laravel integration and storage layout are your responsibility.
How do I install nwtn/php-respimg in a Laravel project?
Run composer require nwtn/php-respimg, then wrap it in an application service rather than calling it from controllers, models, or Blade. There is no documented Laravel service provider, so configuration, storage paths, and dependency injection are yours to wire. Check the package's PHP constraint before installing, and validate it in a clean CI image.
Is nwtn/php-respimg compatible with Laravel 10/11 and PHP 8?
Do not assume compatibility. The evaluation notes likely Laravel 5.x-era wiring and PHP 5.6/7.x idioms, so PHP 8 and Laravel 10/11 support must be proven in a short spike. Inspect composer constraints, run a clean install, and plan for a fork if the package does not pass your runtime tests.
Does nwtn/php-respimg generate srcset and picture markup automatically?
Yes, it can generate srcset and picture markup from configured breakpoints and pixel-density multipliers. You still need to own the sizes attribute, art direction decisions, and URL layout in your Blade component. Keep derivative naming in your application so cached URLs survive a backend swap.
Which image processors does nwtn/php-respimg support?
It supports pluggable image engines, with ImageMagick/Imagick and GD named in the package description. It also supports WebP and JPEG XR output alongside JPEG and PNG, but actual format support depends on the installed binaries and PHP extensions. Bake those dependencies into a dedicated worker image and test each target format.
Should I use nwtn/php-respimg for on-the-fly image resizing?
It is a poor fit for request-time resizing or arbitrary URL-parameterized sizes. Treat nwtn/php-respimg as a batch/build-time workflow that generates a known set of derivative widths and caches them on disk or object storage. If you need on-the-fly transforms or edge format negotiation, evaluate imgproxy, Cloudinary, or imgix instead.
Can nwtn/php-respimg write derivatives to S3 or object storage?
The package documentation does not describe object-storage writers, so assume local filesystem output until proven otherwise. Design your own derivative naming, manifest, upload step, and cache invalidation around it. Test an S3 or object-storage adapter in your spike before committing to the package.
What should I check in a production spike for nwtn/php-respimg?
Run a 2-3 day spike that installs from a clean image on your exact PHP, Laravel, and CI runtime. Confirm whether Node or ImageMagick optimizers are build-time only, whether transforms can run in a dedicated worker, how failures are surfaced, and whether S3 is supported. Benchmark time, peak RSS, and output size for a 4 MB/4000 px JPEG across five widths plus a large PNG and WebP target. Also record license, last commit date, open issues, and whether a PHP 8 fork is required; maintainer risk is high due to zero stars, zero tracked dependents, and a single-author pattern.
Is nwtn/php-respimg safe to run with user-uploaded images?
Treat it as a security-sensitive subprocess. Filenames and paths cross into ImageMagick or GD tooling, so path-escape and command-injection review are mandatory. Error handling is likely coarse, such as exit codes only, so your code must detect partial writes and silent no-ops. Run transforms in a restricted worker with validated inputs and least-privilege filesystem access.
How does nwtn/php-respimg compare with imgproxy, Cloudinary, or imgix?
Use nwtn/php-respimg as a self-hosted build baseline when you need stable breakpoints and cached derivatives. It can be a cheap performance win behind an internal ImageTransformer contract, but you must own derivative naming, storage, cache invalidation, and the native toolchain forever. If your roadmap requires request-time transforms, AVIF/WebP negotiation, or CDN-on-the-fly resizing, prefer imgproxy, Cloudinary, or imgix.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
users-au/socialite-provider
twidpay/twid-logger
mrnewport/laravel-plaid
mrnewport/laravel-repo
mrnewport/laravel-docsign
mrnewport/laravel-stow
mrnewport/laravel-flow
mrnewport/laravel-priceable
mrnewport/laravel-nestedterms
fredmeng/laravel-apidoc-generator
itstructure/laravel-multilingual-tools
pdustdar/elasticsearch
markupai/php-sdk
rlacerda83/lumem-microservice-shipment
uni-method/symfony-lib
tacticmedia/scim-server-bundle
neika-ai/symfony-bundle
mattleads/agent-publishing-bundle
glavweb/framework-bundle
glavweb/extra-bundle