Outsource Laravel Development Partner - $3200/Month | Bacancy

Laravel 9.45 Released

Published on by

Laravel 9.45 Released image

Never Miss a Laravel Release 🚀

Sign up and get an email with each new Laravel release

The Laravel team released 9.45 this week with custom component search paths, a new validation rule, router convenience for ULID route params, and more:

Custom component search paths

Taylor Otwell contributed the registration of root-level anonymous component search paths. This is convenient for projects that have components in various locations.

To configure a search path, add the following to the boot() method within a registered service provider:

 
Blade::anonymousComponentPath(__DIR__.'/../components');
// I.e., `<x-panel />`
 
// With a prefixed namespace
Blade::anonymousComponentPath(
__DIR__.'/../components',
'dashboard'
);
 
// I.e., `<x-dashboard::panel />`

See theAnonymous Component Paths documentation for further details.

Decimal validation rule

@Pusparaj contributed a decimal validation rule with a min, max configuration. Here are a few examples from the pull request tests:

// Passes validation
$v = new Validator($trans, ['foo' => '1.234'], ['foo' => 'Decimal:2,3']);
$this->assertTrue($v->passes());
 
// Fails validation
$v = new Validator($trans, ['foo' => '1.2345'], ['foo' => 'Decimal:2,3']);
$this->assertFalse($v->passes());

Here's how the rule works:

  1. decimal:2 is exactly two digits on the fractional part
  2. decimal:2,3 either two or three digits on the fractional part
  3. decimal:0,3 values must have at most three digits in the fractional part and can include zero digits (i.e., integer)

"whereUlid()" Route Support

Jamshed Javed contributed whereUlid() route support to the collection of commonly-used regular expressions. Given you want a route id param to match a ULID, you'd use the following now:

Route::get('/user/{id}', function ($id) {
//
})->whereUlid('id');

Release Notes

You can see the complete list of new features and updates below and the diff between 9.44.0 and 9.45.0 on GitHub. The following release notes are directly from the changelog:

v9.45.0

Added

  • Allows the registration of custom, root-level anonymous component search paths. (#45338, 1ff0379)
  • Added decimal validation rule (#45356, e89b2b0)
  • Added align property to button mail component (#45362)
  • Added whereUlid(param) support for routing (#45372)

Fixed

  • Fixed single line @php statements to not be parsed as php blocks in BladeCompiler (#45333)
  • Added missing code to set locale from model preferred locale in Maillable (#45308)

Changed

  • Vite: ability to prevent preload tag generation from attribute resolver callback (#45283)
  • Deprecation Test Improvements (#45317)
  • Do not allow nested arrays in whereIn method (140c3a8)
  • Bump ramsey/uuid (#45367)
Paul Redmond photo

Staff writer at Laravel News. Full stack web developer and author.

Cube

Laravel Newsletter

Join 40k+ other developers and never miss out on new tips, tutorials, and more.

image
Tinkerwell

Enjoy coding and debugging in an editor designed for fast feedback and quick iterations. It's like a shell for your application – but with multi-line editing, code completion, and more.

Visit Tinkerwell
Curotec logo

Curotec

World class Laravel experts with GenAI dev skills. LATAM-based, embedded engineers that ship fast, communicate clearly, and elevate your product. No bloat, no BS.

Curotec
Bacancy logo

Bacancy

Supercharge your project with a seasoned Laravel developer with 4-6 years of experience for just $3200/month. Get 160 hours of dedicated expertise & a risk-free 15-day trial. Schedule a call now!

Bacancy
Tinkerwell logo

Tinkerwell

The must-have code runner for Laravel developers. Tinker with AI, autocompletion and instant feedback on local and production environments.

Tinkerwell
Cut PHP Code Review Time & Bugs into Half with CodeRabbit logo

Cut PHP Code Review Time & Bugs into Half with CodeRabbit

CodeRabbit is an AI-powered code review tool that specializes in PHP and Laravel, running PHPStan and offering automated PR analysis, security checks, and custom review features while remaining free for open-source projects.

Cut PHP Code Review Time & Bugs into Half with CodeRabbit
Get expert guidance in a few days with a Laravel code review logo

Get expert guidance in a few days with a Laravel code review

Expert code review! Get clear, practical feedback from two Laravel devs with 10+ years of experience helping teams build better apps.

Get expert guidance in a few days with a Laravel code review
Kirschbaum logo

Kirschbaum

Providing innovation and stability to ensure your web application succeeds.

Kirschbaum
Shift logo

Shift

Running an old Laravel version? Instant, automated Laravel upgrades and code modernization to keep your applications fresh.

Shift
Harpoon: Next generation time tracking and invoicing logo

Harpoon: Next generation time tracking and invoicing

The next generation time-tracking and billing software that helps your agency plan and forecast a profitable future.

Harpoon: Next generation time tracking and invoicing
Lucky Media logo

Lucky Media

Get Lucky Now - the ideal choice for Laravel Development, with over a decade of experience!

Lucky Media
Lunar: Laravel E-Commerce logo

Lunar: Laravel E-Commerce

E-Commerce for Laravel. An open-source package that brings the power of modern headless e-commerce functionality to Laravel.

Lunar: Laravel E-Commerce
SaaSykit: Laravel SaaS Starter Kit logo

SaaSykit: Laravel SaaS Starter Kit

SaaSykit is a Multi-tenant Laravel SaaS Starter Kit that comes with all features required to run a modern SaaS. Payments, Beautiful Checkout, Admin Panel, User dashboard, Auth, Ready Components, Stats, Blog, Docs and more.

SaaSykit: Laravel SaaS Starter Kit

The latest

View all →
A new beta of Laravel Wayfinder just dropped image

A new beta of Laravel Wayfinder just dropped

Read article
Ben Bjurstrom: Laravel is the best Vibecoding stack for 2026 image

Ben Bjurstrom: Laravel is the best Vibecoding stack for 2026

Read article
Laravel Altitude - Opinionated Claude Code agents and commands for TALL stack development image

Laravel Altitude - Opinionated Claude Code agents and commands for TALL stack development

Read article
JSON:API Resource in Laravel 12.45 image

JSON:API Resource in Laravel 12.45

Read article
Caching With MongoDB for Faster Laravel Apps image

Caching With MongoDB for Faster Laravel Apps

Read article
Laravel 12.44 Adds HTTP Client afterResponse() Callbacks image

Laravel 12.44 Adds HTTP Client afterResponse() Callbacks

Read article