/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $list = Todolist::all(); return view('Lists.index', compact('list')); }
public function getIndex() { $lists = Todolist::all(); return view('lists.index')->with('lists', $lists); }
/** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { // $lists = Todolist::all(); return View('lists.index', compact('lists')); }