Laravel 10 Breeze Authentication Example
In this tutorial we will learn how to create a laravel 10 project using the breeze package. Laravel Breeze is a minimalist authentication scaffolding package for Laravel 10. It publishes controllers files, views and routes for authentication system in laravel 10 application. It provides a simple and secure foundation for user login, registration, password reset, email verification, and profile editing, all with beautiful Blade templates and optional Tailwind CSS styling.
Prior to the introduction of Laravel Breeze in Laravel, the laravel/ui package was the go-to option for developers seeking out-of-the-box authentication scaffolding. Offering both Bootstrap and React implementations, it provided pre-built components for login, registration, password reset, and email verification. However, due to its broader scope and additional features, laravel/ui came with a bit more setup complexity than the streamlined minimalism of Breeze.
Step 1: Install the Laravel project
First open the window terminal and Install a new laravel application using the below command.
composer create-project laravel/laravel example-app
Step 2 : Move to the project directory
cd example-app
Step 3: Add breeze package to Laravel
composer require laravel/breeze
Step 4 : Install laravel breeze for simple auth scaffolding. So let's run the command below.
php artisan breeze:install
Now you will get the below option to choose.
Which Breeze stack would you like to install? Blade with Alpine ................................................................................... blade Livewire (Volt Class API) with Alpine ............................................................ livewire Livewire (Volt Functional API) with Alpine ............................................ livewire-functional React with Inertia .................................................................................. react Vue with Inertia ...................................................................................... vue API only .............................................................................................. api
Choose the first option (Blade with Alpine) by entering blade in command prompt and pass other options as per your requirement.
Step 5 : Create a database in MySQL and add database name in .env file and run below migration command in your terminal.
php artisan migrate
Step 6 : Now you can run the php artisan serve command to start the development server and visit to http://localhost:8000/ URL.
php artisan serve
If you like what you are reading, please consider buying us a coffee ( or 2 ) as a token of appreciation.
Don't forget to share this article! Help us spread the word by clicking the share button below.
We appreciate your support and are committed to providing you valuable and informative content.
We are thankful for your never ending support.
Random Code Snippet Queries: Laravel
- Call to undefined function Illuminate\Encryption\openssl_cipher_iv_length()
- How to get the id of last record from collection object in laravel view
- How to send email in laravel
- Import/Use Storage facade in laravel
- SQLSTATE[23000]: Integrity constraint violation: 1022 Can't write; duplicate key in table
- Send OTP using textlocal api in laravel
- Global scope in Laravel with example
- How to get CSRF token in laravel controller
- Create records using relationship in laravel
- How to randomly get the user id from users table in laravel
- Get comma separated email from input array
- First and last item of the array using foreach iteration in laravel blade
- How to check find method executed successfully in laravel
- Call to undefined relationship [user] on model [App\Models\Post]
- How to validate URL with https using regex in laravel
- SQLSTATE[42S21]: Column already exists: 1060 Duplicate column name 'user_id'
- Symlink(): No such file or directory
- How to create laravel project using jetstream
- How to customize pagination view in laravel
- Class "App\Http\Controllers\Auth\Verified" not found
- Pagination in laravel
- Seed database using SQL file in Laravel
- Attempt to read property "avatar" on null in Laravel
- 419 page expired error in Laravel
- How to add class to tr in table using foreach in laravel