Laravel Nova 4 - 2023 Update

Ruslan Osipov
Author: Ruslan Osipov

Laravel Nova is a administrative panel for Laravel applications. Laravel Nova 4.0 was released on April 3, 2022 and includes a number of new features and improvements.

Laravel Nova 4 [new version]

New in Laravel Nova 4.0

The new version of Laravel Nova has been built with Inertia.js - the modern layer using a new approach to building server-driven SPA.

Dependencies have been changed.

Currently, the server-side's minimum PHP version is PHP7.3+ and Laravel Framework 8.0+.

Several packages have also been updated:

  • doctrine/dbal

  • laravel/ui

  • symfony/*

  • cakephp/chronos

On the client-side, flatpickr and moment.js libraries have been removed

You must follow the official website instructions when you decide to update your Laravel Nova from version 3+ to 4.

Laravel Nova 4.0 is the latest version of the administrative panel for Laravel applications and builds upon the improvements made in the previous 3.x versions.

One of the major updates in Nova 4.0 is implementing a fully redesigned and responsive interface built on top of the Tailwind CSS 2 framework, Vue 3 JavaScript library, and Inertia.js for building single-page applications. This new design also includes support for dark mode.

In addition to the updated design, Nova 4.0 introduces many new features and improvements to make it easier to manage and customize your Laravel application.

Some of these features include the ability to collapse related resources, customize the branding of the Nova interface, receive notifications within the panel, define custom callback actions, create custom fields with dependencies and filters, define custom menus, create new metrics, perform batch actions, and improve search functionality.

These are just a few examples of the many new features and improvements available in Laravel Nova 4.0.

Personal experience with Laravel Nova

As someone who has been using Laravel Nova for several years, I can confidently recommend it as a powerful and feature-rich administrative panel for Laravel applications. Nova provides a user-friendly interface for managing and organizing the various components of a Laravel application, including resources, actions, filters, lenses, and custom fields. The interface is easy to navigate and customize, and the wide range of available features makes it a versatile tool for various use cases.

One of the standout features of Nova is its ability to easily create custom fields and actions, which allows you to tailor the panel to your specific needs and workflow. The support for custom filters and lenses is also a useful tool for organizing and presenting data in a meaningful way to your team or clients.

Overall, I have found Laravel Nova to be an invaluable asset in my work with Laravel applications, and I would recommend it to anyone looking for a robust administrative panel.

FAQs

What is Laravel Nova

Nova is a beautifully-designed administration panel for Laravel. Carefully crafted by the creators of Laravel, Nova is designed to make you the most productive developer in the galaxy.


Why use Laravel Nova?

It's a fast, easily configurable and extendable admin panel with good documentation and an amazing community.


Should I upgrade to Nova 4?

It's entirely up to you. If you want to support creators and don't use 3rd party packages that require the upgrade or your additional packages already support version 4, then go for it.


How to hide Laravel nova filter

You can register a filter for each resource individually by adding them to the `filters` method in the Resource class. If you want to hide a filter for some type of user you can add a condition based on the user's role for example


How does Laravel nova name resources

By default, you should use the same name for your resource as the Class name your help represents. But You can name it however you want if you define your model class in $model static property.


How to check Laravel Nova version

First, you can check the Laravel Nova version in the composer.json file in the `require` section. Check `laravel/nova` package. To check the actual installed version you can look at the `version` field in the `vendor/laravel/nova/composer.json` file. Finally, you can log in to your Laravel Nova admin and look at the bottom of any page for the version number in the footer.


How to import Nova tool class Laravel

You can register your Tools in NovaServiceProvider class under the `tools` method.


How to get current logged in user Laravel Nova

You can get the user from the $request variable ($request->user()) in those methods of your resource class that provide it.


How to update Laravel nova

You can run `composer update` command in your project directory. After updating to a new Nova release, you should be sure to update Nova's JavaScript and CSS assets using `php artisan nova:publish` and clear any cached views with `php artisan view:clear` command. This will ensure the newly-updated Nova version is using the latest versions.


What Laravel nova alternative

The closest alternatives for Laravel Nova are Backpack for Laravel and Filament PHP built with Laravel Livewire.