app/Http/Controllers/TaskController.php
/**
     * Display a listing of the resource.
     *
     * @return \Illuminate\Http\Response
     */
Display a listing of the resource.
@return \Illuminate\Http\Response
Display a listing of the resource . @return \ Illuminate \ Http \ Response
public function index()
    {
      $tasks = Task::orderBy('id','desc')->get();
      return view('tasks.index', compact('tasks'));
    }
public function index ( ) { $ tasks = Task :: orderBy ( 'id' , 'desc' ) -> get ( ) ; return view ( 'tasks.index' , compact ( 'tasks' ) ) ; }
Display a listing of the resource.
Display a listing of the resource .