img
AboutContactBlogGet in touch

6 min read

What’s New In Laravel Herd Pro? Introducing The New Features

Interested in generating passive income? Join our partnership program and receive a commission on each new client referral. Learn more.

laravel herd pro

Just a few weeks ago, Laravel Herd released a new update – version 1.4.0. The huge notice in this update is that it comes with a new optional pricing plan – Herd Pro with several essential features integrated into it for a better developer experience.

So, let’s take a look at the exciting new capabilities Laravel Herd Pro brings to the table, including Mail Server, Dump Inspection, Logs Viewer and Xdebug Detection.

Laravel Herd Pro: Mail Server

The first new feature provided by Laravel Herd Pro is email. It offers an SMTP mail server on your local machine that captures all outgoing emails from your application and presents them in an internal email client with added debugging features. The mail server operates using the SMTP protocol; it receives emails but stores them in an internal database instead of sending them to their intended recipients.

Configuration

Projects created through Herd’s site creation wizard or by using the Laravel new command come with pre-configured settings. For other scenarios, you can copy the configuration from the ‘Show Mail’ window (Herd Settings > Mail > Show Mail).

Laravel Herd Pro

After we are done with configuring, each email sent from our application appears in this window. You can inspect the header values of an email by opening the sidebar located at the top right corner of the email window.

Laravel herd pro

You can access the HTML source of the email or its raw content by right-clicking on the email itself. This action opens them in a new window and allows you to view the raw or HTML content of multiple emails simultaneously.

By default, the Herd Pro mail server operates on port 2525, but you can customize this configuration in the settings as needed.

Laravel Herd Pro: Dumps

Dumps is another new highlight from this update. Laravel Herd Pro automatically intercepts all dump() calls in your code and presents them in a separate window rather than rendering them in the browser or CLI.

You can access the dumps window through the Herd system tray menu or via a globally configurable shortcut that you define in the shortcut settings.

To enable dump interception, click on the antenna icon in the window’s title bar. The icon will flash, indicating that the dump interception is activated. Once enabled, you can use the dump() function as usual. Instead of displaying the dump in your browser or terminal, Herd will open a window whenever a new dump is generated. You can also pin the window to the foreground by clicking on the “pin” icon and making sure it remains on top of all other windows.

New dumps are automatically added to the top of the window, and you can clear the window by pressing the icon in the title bar of the dump window. All dumps are searchable which makes it easier for you to find what you are looking for.

Laravel herd pro

Laravel Herd Pro: Log Viewer

Herd Pro features a log viewer, which proves invaluable for local work involving webhooks or queues. Additionally, it enables thorough inspection of log files, simplifying the process of searching within these logs.

Keep in mind that this feature requires PHP 8.0 or a newer version.

To open the log viewer window, you need to configure a hotkey in the Herd shortcuts settings.

Laravel herd pro

Herd continuously checks for new logs every few seconds while the Logs window remains open

Laravel herd pro

The log window automatically displays the latest log file of the most recent project served via Herd. This feature enables quick access to the latest log file, although you can also switch between all projects known to Herd and ready for service.

If your project contains multiple log files, such as when using daily log rotation, you can choose the desired log file from the selection on the left.

The search bar at the top searches through all logs, enabling you to locate all log entries matching your search query. Alternatively, you can press Cmd+F within the text area, displaying the entry details to search within that specific entry.

Herd Pro Xdebug Detection

Herd Pro detects Xdebug headers or breakpoints in PHPStorm and seamlessly routes requests to the PHP process with Xdebug automatically. This ensures optimal site performance for regular requests and offers advanced debugging capabilities with Xdebug when needed.

Setup with PHPStorm

Navigate to Herd Pro’s debugging settings and choose the configuration to detect breakpoints within PHPStorm automatically.

Laravel herd pro

You can follow these steps to ensure seamless integration: When you set or remove a breakpoint in PHPStorm and save the file, a temporary file is generated within your project’s .idea folder. Herd parses these files to detect breakpoints effectively.

You should also remember to enable PHP Debug Connections in PHPStorm after setting the breakpoint, which allows Xdebug to connect seamlessly to PHPStorm.

Setup With Browser Extension

Laravel Herd uses the headers of Xdebug browser extensions, which are available for installation via the Chrome Web Store or Firefox Addons.

Once you activate an Xdebug feature within the browser extension, Herd responds by processing the request through a PHP process equipped with the corresponding Xdebug extensions.

Using Xdebug On The Command Line

You can execute CLI commands using “herd debugs” instead of directly invoking “php”, to make sure that the PHP binary with Xdebug enabled is utilized. For example, when you’re debugging an artisan command, simply run “herd debug artisan your:command” to activate your breakpoint.

img

Meet the authors

We are a 200+ people agency and provide product design, software development, and creative growth marketing services to companies ranging from fresh startups to established enterprises. Our work has earned us 100+ international awards, partnerships with Laravel, Vue, Meta, and Google, and the title of Georgia’s agency of the year in 2019 and 2021.

img
Contact us