-3

When I run this command: php artisan make:auth

I get an error:

command "make:auth" is not defined.

enter image description here

I have a problem in command with php artisan make:auth. How can I create a login in laravel

Udhav Sarvaiya
  • 9,380
  • 13
  • 53
  • 64
Choqoz
  • 15
  • 3
  • run `php artisan --version` If it's `>= 6` then as @salaman-zafar said, `make:auth` is no longer in the default install of version 6 – Novocaine Sep 20 '19 at 09:19
  • 7
    Possible duplicate of [Artisan command "make:auth" is not defined in Laravel 6](https://stackoverflow.com/questions/57774231/artisan-command-makeauth-is-not-defined-in-laravel-6) – dparoli Sep 20 '19 at 09:20
  • the laravel version is 6.0.3 – Choqoz Sep 20 '19 at 09:30

2 Answers2

5

In Laravel 6 auth command has been removed and authentication scaffolding has been moved as separate package named laravel/ui

Here you can read about Laravel 6 and laravel/ui and also here you can read about laravel/ui in laravel documentation

Udhav Sarvaiya
  • 9,380
  • 13
  • 53
  • 64
Salman Zafar
  • 3,844
  • 5
  • 20
  • 43
0

Laravel 6.0 has removed this command:php artisan make:auth

Update for Laravel 6: The command to implement Auth is as follows:

composer require laravel/ui
php artisan ui vue --auth

This command will install a layout view, registration and login views, as well as routes for all authentication end-points. A HomeController will also be generated


NOTE: If your login page only shows plain HTML. And CSS is not loading properly then run this two command:

npm install
npm run dev
Udhav Sarvaiya
  • 9,380
  • 13
  • 53
  • 64