sortby as and dsc laravel code example
Example 1: order By Asc in laravbel
->orderBy('id', 'DESC');
Example 2: get all sort by laravel
$results = Project::orderBy('name')->get();
->orderBy('id', 'DESC');
$results = Project::orderBy('name')->get();