๐ How to Create a New Laravel Project Quickly!
๐น Method 1: Using Composer Create-Project
Command:
composer create-project --prefer-dist laravel/laravel LoginAuth "11.*"
Time Taken: โฑ๏ธ Approximately 2โ5 minutes
โ
Directly installs the specific Laravel version you mention.
โ
Good for complete control over the setup.
๐น Method 2: Using Laravel Installer
Commands:
composer global require laravel/installer
laravel new LoginAuth
Time Taken: โฑ๏ธ Approximately 30โ60 seconds
โ
Faster installation compared to create-project.
โ
Best if you frequently create new Laravel projects.
๐น Method 3: Using Docker (Laravel Sail)
Command:
curl -s "https://laravel.build/LoginAuth" | bash
cd LoginAuth
./vendor/bin/sail up
Time Taken: โฑ๏ธ Around 1 minute
โ
Ideal for containerized development.
โ
Comes pre-configured with PHP, MySQL, Redis, and more.