Best of PHPJune 2026

  1. 1
    Article
    Avatar of lnLaravel News·11w

    Refresh Your Laravel Database Without Dropping Every Table

    Custom Fresh is a Laravel package that adds a `fresh:custom` Artisan command as an alternative to `migrate:fresh`. Instead of dropping every table, it lets you specify which tables to preserve using comma-separated names or glob patterns (e.g., `subscription_*`). It includes a `--explain` flag for dry-run previews, `--database` for targeting specific connections, a publishable config file for setting persistent defaults, and three lifecycle events (`RefreshingDatabase`, `TablesDropped`, `DatabaseRefreshed`) for hooking into the refresh process. Requires PHP 8.2+ and supports Laravel 10–13.

  2. 2
    Article
    Avatar of lnLaravel News·10w

    Lattice: Describe Inertia UIs in PHP

    Lattice is a server-driven UI framework for Laravel that lets developers define pages, forms, tables, and actions entirely in PHP, which are then serialized and rendered as typed React components via Inertia.js. Pages are PHP classes with an `#[AsPage]` attribute that auto-registers routes. Forms extend `FormDefinition` with Laravel validation rules and optional live validation via Precognition. Tables extend `EloquentTableDefinition` with declarative columns supporting sorting, filtering, and pagination. Actions return `ActionResult` objects carrying client-side effects like toasts and component reloads. The server becomes the single source of truth for UI structure, while the React client only handles rendering.

  3. 3
    Article
    Avatar of lnLaravel News·11w

    Version-Controlled Documentation Inside Your Laravel App with Laradocs

    Laradocs is a Laravel package that turns markdown files stored alongside your code into a fully rendered documentation site at /docs. Key features include folder-based navigation, YAML front-matter metadata for routing and ordering, CommonMark-powered markdown rendering with GitHub-flavored extensions, reusable variables and macros via a service provider, smart file-change-aware caching, and automatic SEO meta tags with sitemap generation. It supports PHP 8.2+ and Laravel 11–13.

  4. 4
    Article
    Avatar of lnLaravel News·12w

    Scheduler List: A Web Dashboard for Laravel's Scheduled Tasks

    Scheduler List is a Laravel package that provides a Pulse-style web dashboard for viewing and managing scheduled tasks. It displays all registered tasks with their cron expressions, next run times, timezones, and constraints. An optional manual execution feature lets you trigger tasks from the browser and stream their output in real time. The dashboard is disabled by default, protected by auth middleware, and supports authorization gates to restrict access. Install via Composer and enable through environment variables.

  5. 5
    Article
    Avatar of freekFREEK.DEV·10w

    How PHP Attributes Changed the Way I Write Livewire

    Bert De Swaef explores how PHP attributes improve Livewire component development by attaching validation rules, URL sync, and event listeners directly to the properties and methods they belong to. This approach reduces mental overhead, improves IDE support, and makes components more self-documenting.

  6. 6
    Article
    Avatar of phpPHP·12w

    PHP: PHP 8.5.7 Release Announcement

    The PHP development team has released PHP 8.5.7, a bug fix update for the PHP 8.5 branch. All PHP 8.5 users are encouraged to upgrade. Source downloads and Windows binaries are available on the official PHP downloads page, with the full list of changes in the ChangeLog.

  7. 7
    Article
    Avatar of lnLaravel News·10w

    Monitor Laravel Queues, Commands, and Schedulers on Any Driver with Vigilance

    Vigilance is a self-hosted Laravel monitoring dashboard that tracks jobs, artisan commands, and scheduled tasks across any queue driver (Redis, SQS, database, Beanstalkd, sync). Unlike Horizon (Redis-only) or Telescope (local debugging), it writes a single lifecycle record per run, capturing parameters, exit codes, and exception traces. Key features include configurable sampling rates to control storage costs, manual job dispatch from auto-generated typed forms via reflection, custom business metrics (counters/gauges), Real User Monitoring with Core Web Vitals, exception grouping, SLO tracking, N+1 detection, uptime checks, log explorer, alerting integrations, and an MCP server for AI agent access. Requires PHP 8.2+, Laravel 12/13, and Livewire 3.5+/4. MIT-licensed.

  8. 8
    Article
    Avatar of wendelladrielW endell Adriel·11w

    Eloquent Query Classes Pattern

    The Eloquent Query Classes pattern organizes complex or reusable database queries in Laravel by wrapping them in small, focused classes with a single `handle()` method. Unlike the Repository Pattern, these classes don't abstract away Eloquent — they give important business queries a dedicated name and home. The post covers when to use query classes vs. local scopes, how to structure them in small and large apps, whether to return a Builder or execute the query directly, how to handle write operations, and how to test them with Pest and database factories. Practical guidelines include naming classes after business questions, keeping only one public method, and avoiding over-abstraction.

  9. 9
    Article
    Avatar of lnLaravel News·10w

    The artisan dev Command in Laravel 13.16.0

    Laravel 13.16.0 ships four notable additions. The new `php artisan dev` command runs development processes (server, queue worker, log tailing, Vite) concurrently, replacing the `composer dev` script with application-level configuration via a `DevCommands` class. A `whenFilledEnum()` method on requests simplifies typed enum handling by combining the filled check, `tryFrom()` cast, and null guard into one call. The `withCookies()` method moves from `RedirectResponse` to `ResponseTrait`, making it available on all response types including `JsonResponse`. An array-based maintenance mode driver is added specifically for parallel testing scenarios where file and cache drivers cause issues. Additional fixes cover shell quoting in scheduled commands, batch job handling, queue attributes on traits, and JSON Schema deserialization safety.

  10. 10
    Article
    Avatar of larablogLarablog·9w

    Is Laravel Too Magical?

    An exploration of Laravel's 'magical' features — specifically facades and the service container — revealing how they work under the hood and demonstrating that the apparent magic is built on standard PHP principles.

  11. 11
    Article
    Avatar of freekFREEK.DEV·11w

    Multi-Agent Orchestration in Laravel: When You Actually Need It

    A practical guide on when multi-agent orchestration is actually warranted in Laravel applications. The core argument: a separate agent only justifies its existence when it requires its own model, tools, or instructions. Covers delegation tradeoffs, context handoff between agents, and how to validate routing logic before it introduces costly latency overhead.

  12. 12
    Article
    Avatar of lnLaravel News·10w

    Watch the Teaser for 'The Story of PHP' Documentary

    CultRepo has released a teaser for 'The Story of PHP', a JetBrains-sponsored documentary covering three decades of PHP's history. The film features interviews with key figures including Taylor Otwell (Laravel), Fabien Potencier (Symfony), Nikita Popov (PHP core), Nils Adermann (Composer), and others. It explores PHP's evolution from spaghetti code era through framework wars to its current dominance powering major content platforms and CMS communities. The full documentary is expected later this year.

  13. 13
    Article
    Avatar of jetbrainsJetBrains·11w

    Contribute to the State of PHP Survey

    JetBrains and The PHP Foundation are launching the first annual State of PHP survey to gather data on PHP developer trends, including experience levels, framework preferences, and AI tool usage. The goal is to produce a representative picture of the PHP ecosystem, with results published in October 2026. Participants can enter a drawing to win one of five EUR 500 vouchers.

  14. 14
    Article
    Avatar of wendelladrielW endell Adriel·12w

    Improving Laravel Architecture With Expressive

    Expressive is a Laravel package that provides typed objects as a boundary between Eloquent models and business logic. Instead of passing Eloquent models everywhere, you convert them to fully typed PHP objects with explicit properties, enums, and nullability. Business actions then depend on these typed objects rather than the full database model, preventing accidental DB calls, improving static analysis, and making code easier to reason about. The package includes a generator and sync command to keep Expressive classes aligned with model changes. The author recommends using it selectively for complex business flows rather than replacing all Eloquent usage.

  15. 15
    Article
    Avatar of wpmayorWP Mayor·9w

    Who’s Left to Build WordPress?

    WordPress still powers 41.5% of the web but faces four converging pressures: an aging developer base, a cultural shift away from self-hosted sites toward managed platforms, AI tools dismantling the simple-site market that WordPress historically dominated, and a governance crisis stemming from Matt Mullenweg's unchecked control over WordPress.org infrastructure. The plugin economy is bifurcating — enterprise and commerce use cases remain sticky, but undifferentiated plugins whose functionality AI can replicate have no defensible future. The Automattic vs. WP Engine legal battle, near-total withdrawal of sponsored contribution hours, and suppression of community voices have damaged trust among the developers WordPress most needs. The author, a decade-long WordPress plugin business owner, argues the platform is narrowing into a serious-end tool while the casual and mid-market segments erode, and that only governance reform — not market forces — is reversible.

  16. 16
    Article
    Avatar of lnLaravel News·10w

    Filament Storage Monitor: Track Disk Usage From Your Filament Dashboard

    Filament Storage Monitor is a Laravel Filament plugin that adds a dashboard widget for tracking server disk usage. It supports multiple partitions via addDisk() and laravelDisk() methods, custom labels, colors, and Heroicons. Features include per-disk authorization using closures, compact mode for a smaller footprint, configurable error handling for unresolvable paths, and standard layout controls. A known limitation is that two paths on the same partition report identical stats; directory-level size calculation is planned for a future release.

  17. 17
    Video
    Avatar of laraveldailyLaravel Daily·12w

    NativePHP: My Android App is on Play Store! (+new YouTube channel)

    A Laravel developer shares their experience building and publishing an Android app on Google Play Store using NativePHP, Laravel, and Livewire. The app, called Checklisty, is a simple recurring checklist tool built in about a week. The post covers the full journey: coding challenges with Tailwind CSS on real devices, the Google Play registration process ($25 one-time fee), mandatory testing phases requiring 12+ testers and 14-day waiting periods, and a total of one month from submission to production. Community feedback noted some lag and a 43MB app size. The author also announces a new YouTube channel, NativePHP Daily, dedicated to mobile development with NativePHP.

  18. 18
    Article
    Avatar of symfonySymfony·11w

    New in Twig 4.0: A New for Loop for Twig 4.0 (Symfony Blog)

    Twig 4.0 overhauls the `for` loop with several long-awaited improvements. The key change is that `loop.last` now works with any iterator (generators, Traversable objects) by reading one item ahead, not just arrays. New helpers include `loop.previous`/`loop.next` for accessing surrounding values, `loop.changed()` for grouping logic, and `loop.cycle()` for alternating CSS classes. The `if` condition on `for` tags returns after being removed in Twig 3.0. Recursive loops are now a first-class feature via the `loop()` function, replacing the verbose macro workaround. The upgrade path is smooth: templates running deprecation-free on Twig 3 render identically on Twig 4, with the only breaking change being clearer errors for non-countable iterators.

  19. 19
    Article
    Avatar of lnLaravel News·11w

    JSON Schema Deserialization in Laravel 13.14

    Laravel 13.14.0 ships with several new features and bug fixes. The headline addition is JsonSchema::fromArray(), a deserializer that converts raw JSON Schema arrays back into Type objects, completing the round-trip with the existing serializer. Other changes include a fix for queue job inheritance so child class properties correctly override parent-declared queue attributes, a new queue property on InspectedJob for visibility into pending jobs, and a bug fix for falsy JSON payloads (false, 0, null) not being cached in HTTP client responses. The release also includes mail embed fixes, null header handling, and Symfony 8.1 compatibility.

  20. 20
    Video
    Avatar of laraveldailyLaravel Daily·10w

    NEW Laravel (Unofficial) API Starter Kit: Built by Me and Fable 5

    An unofficial Laravel API starter kit built with Claude (Fable 5) is presented as an alternative to the official starter kits, which currently lack a pure API option. The kit includes Laravel Sanctum-based authentication with versioned routes (v1), registration, login, password reset, token management, and API documentation via Scramble — all without a frontend layer, npm, or Laravel Fortify. The official Laravel team is working on their own API starter kit expected in 2026, but this project offers an immediate solution for developers who want a clean, API-only Laravel project scaffold.

  21. 21
    Article
    Avatar of lnLaravel News·12w

    Community Laravel Extension for Zed

    Laravel for Zed is a community LSP extension for the Zed editor that brings deep Laravel awareness through static analysis of PHP and Blade files using tree-sitter. Key features include go-to-definition for views, routes, config keys, translations, env values, middleware, and container bindings; hover cards; find references; and atomic rename across the entire project. Autocomplete covers model properties, query-chain methods, Blade variables, and Laravel Pennant flags. Schema-aware diagnostics optionally connect to your real database (MySQL, PostgreSQL, SQLite, SQL Server) to catch typos in column and relation names. Blade editing gains directive completion, smart bracket expansion, and outline panel integration. The extension indexes all PHP and Blade files at startup with on-disk caching for fast restarts, and is installable directly from the Zed extensions marketplace or built from source via Cargo.

  22. 22
    Article
    Avatar of lnLaravel News·12w

    Parsel: Parse PDFs, Office Documents, and Images in PHP

    Parsel is a PHP 8.4 package that wraps the liteparse `lit` CLI to extract text, structured data, and screenshots from PDFs, Word documents, spreadsheets, presentations, and images — all locally without sending files to external services. It provides a fluent API with features like page selection, lazy streaming for large files, OCR support via Tesseract, password-protected file handling, DPI control, and a fake runner for testing without the binary. Install via Composer and use `vendor/bin/parsel-install-lit` to set up the underlying binary.

  23. 23
    Article
    Avatar of thedailywtfThe Daily WTF·12w

    Let's Be Facebook!

    A cautionary tale from circa 2012 about a poorly managed web project that spiraled over budget and past deadlines. After a year and a half of development in C#, the CEO decided to rewrite the entire system in PHP because Facebook used it. Developers estimated 2–3 weeks for the rewrite; the experienced consultant said 5+ months. He was fired for being 'not forward-thinking enough.' The rewrite took nearly 8 months — validating his estimate exactly.

  24. 24
    Article
    Avatar of freekFREEK.DEV·11w

    Logging is here!

    Flare, the error tracking service for Laravel and PHP apps, now supports log collection. The new feature brings real-time log filtering and search into Flare's existing interface, alongside a new SDK release to get started.

  25. 25
    Article
    Avatar of lnLaravel News·11w

    Toolkit: Reusable AI Tools for the Laravel AI SDK

    Toolkit is a community catalog of reusable, independently installable Composer packages for the Laravel AI SDK. Each tool implements the Laravel AI Tool contract with a description, schema, and handle method — no shared core or service providers required. Available tools include a safe calculator (using a recursive-descent parser instead of eval()), a read-only database query tool with SQL injection guardrails, and web search/research integrations for Exa, Perplexity, Tavily, and JigsawStack. Configuration is handled via the existing Laravel AI SDK config file, and API errors are returned as strings so agents can recover gracefully.