Solution:
As blade don’t have import system to use Carbon\Carbon
import like that you have to use Carbon\Carbon::
in blade
<td class="uppercase">{{ Carbon\Carbon::createFromTimeString($data->time)->format('g:i a') }}</td>
ref links
https://laracasts.com/discuss/channels/laravel/how-to-format-a-carbon-date-inside-blade?page=1
https://carbon.nesbot.com/docs/
and best approach is use laravel accessor
in your model
public function getTimeFormatedAttribute()
{
return \Carbon\Carbon::createFromTimeString($this->time)->format('g:i a')
}
then in blade you can
<td class="uppercase">{{ $data->time_formated }}</td>