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(Request $request)
    {
        $tasks = $this->task_service->list(auth()->user(), $request->q ?? '');
        return TaskResource::collection($tasks);
    }
public function index ( Request $ request ) { $ tasks = $ this -> task_service -> list ( auth ( ) -> user ( ) , $ request -> q ?? '' ) ; return TaskResource :: collection ( $ tasks ) ; }
Display a listing of the resource.
Display a listing of the resource .