You get this message: In order to use the Auth::routes() method, please install the laravel/ui package.
So
composer require laravel/ui
Documentation: https://laravel.com/docs/7.x/authentication#authentication-quickstart
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I'm trying to deploy my site to heroku. I deployed around 3 more sites and they never caused any problems. However this site is my first site where I am using the build in Auth routes from laravel. I already tried to google this, but I can't seem to find anything about it. I'm receiving this error:
- Installing laravel/tinker (v2.4.0): Downloading (100%)
Generating optimized autoload files
> Illuminate\Foundation\ComposerScripts::postAutoloadDump
> @php artisan package:discover --ansi
In Auth.php line 56:
In order to use the Auth::routes() method, please install the laravel/ui pa
ckage.
Script @php artisan package:discover --ansi handling the post-autoload-dump event returned with error code 1
! WARNING: A post-autoload-dump script terminated with an error
! ERROR: Dependency installation failed!
!
! The 'composer install' process failed with an error. The cause
! may be the download or installation of packages, or a pre- or
! post-install hook (e.g. a 'post-install-cmd' item in 'scripts')
! in your 'composer.json'.
!
! Typical error cases are out-of-date or missing parts of code,
! timeouts when making external connections, or memory limits.
!
! Check the above error output closely to determine the cause of
! the problem, ensure the code you're pushing is functioning
! properly, and that all local changes are committed correctly.
!
! For more information on builds for PHP on Heroku, refer to
! https://devcenter.heroku.com/articles/php-support
!
! REMINDER: the following warnings were emitted during the build;
! check the details above, as they may be related to this error:
! - A post-autoload-dump script terminated with an error
! Push rejected, failed to compile PHP app.
! Push failed
You get this message: In order to use the Auth::routes() method, please install the laravel/ui package.
So
composer require laravel/ui
Documentation: https://laravel.com/docs/7.x/authentication#authentication-quickstart
Please or to participate in this conversation.