Laravel: From Web to API with Services [New Course]

preview_player
Показать описание
If you have a web project with Laravel and you're asked to create a mobile API on top, how would you deal with repeatable code?

Links mentioned in the video:

- - - - -

Support the channel by checking out my products:

- - - - -
Other places to follow:
Рекомендации по теме
Комментарии
Автор

Remember to not manually return errors from service class, do not interact with endpoint specific functionsor methods.

With service classes I usually through exceptions

And i do not litter my controllers with try catch blocks

Instead I specify the render method in the exception class itself

I also in most cases have a base class with the exception remder method and other exceptions inherit from it

yungifez
Автор

Just enough content to keep some of us busy and active.
Thank you sir.

blessdarah
Автор

Congratulations, the video is very dynamic and informative.

brunomoraes
Автор

Like always, your content is amazing! Povilas, I’d like to ask, do you plan to launch a course/tutorial on how to integrate a Laravel/Vue SPA with auth0 (google login)?

ikarolaborda
Автор

Hello!
As I see, you pass arrays into services.
And what do you think about DTO?
It could be more robust to use dtos to pass borders between controllers and services.

al.e.k
Автор

How do you set $restaurants equal to DB::transaction result while not returning anything from the DB::transaction call ? That doesn't seem right. Another place where I noticed something weird is that you've had a "return" statement in the DB transaction prior to doing $user->notify() call, which should mean that $user->notify() will never get called

Novica
Автор

I working on a project right now and use vue js for the api and in the controllers i use if request wants json return response for it, is this approrch i took is a good way or not? it's my first project that i use api for it

script_tinkerers
Автор

what do u thing use webpack without using vite ?

alvido
Автор

Are laravel based api secure based on their framwork

qsthnwi