to upload
$file = Storage::disk('public')->putFileAs($folder,$request->file('file_input'),$filename);
to download
$headers = array(
'Content-Type:'.$file->mime_type,
);
$path = storage_path('app/public'.'/'.$folder.'/'.$filename);
// $path is the link to the file use it in <img> src or download the file like below:
return response()->download($path, $filename, $headers);
NOT CLAIMING TO BE THE PERFECT OR SECURE SOLUTION BUT THIS WORKED FOR ME FOR NOW. WILL FIGURE OUT SOMETHING BETTER LATER
PS: Maybe try
$path =Storage::url($folder.'/'.$filename);
to get the URL for the file instead of above method if it works tell me :)