2. bạn cũng có thể tự tạo cho mình lệnh điều kiện riêng có thể gọi trong blade view (ok)
https://viblo.asia/p/tap-13-blade-template-laravel-1VgZv1dRKAw
use Illuminate\Support\Facades\Blade;
public function boot()
{
Blade::if('env', function ($environment) {
return app()->environment($environment);
});
}@env('local')
// The application is in the local environment...
@elseenv('testing')
// The application is in the testing environment...
@else
// The application is not in the local or testing environment...
@endenvPrevious1. Mở rộng Blade (Extending Blade) (chưa đọc đến đây)NextTạo thư mục và tạo file theo artisan (ok)
Last updated