Laravel 5.1 app and home.blade.php missing

后端 未结 3 1548
野的像风
野的像风 2020-12-24 04:10

I created a new project via composer in Laravel 5.1.
I couldn\'t find the app.blade.php.and home.blade.php file, what am I doing wrong?

相关标签:
3条回答
  • 2020-12-24 04:31

    Run php artisan make:auth and it will automatically generate layoyts\app.blade.php and home.blade.php

    0 讨论(0)
  • 2020-12-24 04:43

    If you want to use laravel 5.0 you can download it from their repo here:

    https://github.com/laravel/laravel/tree/5.0

    And here is a video showing how to get started:

    https://scotch.io/tutorials/login-with-the-built-in-laravel-5-scaffolding

    Basically just

    1) run composer install to get the dependencies then

    2) run artisan key:generate to generate your random key for .env file.

    3) set your database info in .env file

    4) run artisan migrate to set up the database

    and you should be set

    0 讨论(0)
  • 2020-12-24 04:56

    You didn't do anything wrong. The Auth Scaffolding was removed from Laravel 5.1. That includes the app.blade.php and the home.blade.php that you mentioned.

    However, you'll still be able to get it back with the Scafold Package :

    1.Add Scafold to your composer.json file in the require : section :

    require : {
            "laravel/framework": "5.1.*",
            "bestmomo/scafold": "dev-master"
    }
    

    or type from terminal :

    composer require bestmomo/scafold dev-master
    

    2.Update composer :

    composer update
    

    3.Add the service provider to your config/app.php :

    Bestmomo\Scafold\ScafoldServiceProvider::class,
    

    4.Publish the views and assets :

    php artisan vendor:publish
    

    Done!

    0 讨论(0)
提交回复
热议问题