Getting outside of comfort zone is very hard, so bravo to Leah for starting her journey publicly. I personally become nervious even only imagining doing live coding and I not remembering something or not knowing very basic thing. I think I need to work on this.
@minthantoo35092 ай бұрын
The legend here!
@nerisonpitogo33142 ай бұрын
yoh bro. Ive used your codeholic THECODEHOLIC hostinger coupon a million times already. :)
@andrewmcburney442511 күн бұрын
Super helpful video! thanks for taking the time to review it. I am coming from a node/react background and jumping into Laravel and really enjoying it. Hearing your thoughts on best practice on certain things is invaluable.
@TalesGrechi2 ай бұрын
I remember that I did a lot of these "Model::all()" mistakes in the past, too... Great video!
@saravanasai23912 ай бұрын
That was really a great review & constructive suggestions. I have seen some videos just roasting the creator for their code. Great job keep doing it.
@bumblebity29022 ай бұрын
In the companies participating for junior positions you get tough love reviews.
@aleAmosin2 ай бұрын
A while ago, I started using Model::query()->find($id) instead of Model::find($id). It's more verbose, but I gain the benefit of autocomplete and IDE intellisense, as it knows that find returns the model and not a mixed type.
@edgarsloskots26172 ай бұрын
My favorite sentence - “What if you have 1M problems in your database”? 😅
@taraqrahman71712 ай бұрын
Thank you. This is what I want. Please keep this forword.
@p30mehrdad2 ай бұрын
with this code review you did the great job. thank you.🌹
@zkabadu2 ай бұрын
She could also return the return value of Quit::create() as the latest created model instead of dismissing the value and fetching it again from the database.
@emmanuelsiziba51422 ай бұрын
Learnt something new... Esp about methods in controller rather than model
@bumblebity29022 ай бұрын
Kudos for Lady courage.
@aimperialdesign65192 ай бұрын
I have also new project. If want to post it, wouldn't it affect exposing the code?! The project was used during the Miss Tabuk 2024 and I'm currently making the version 2 to do users feedback. What ja think?
@LaravelDaily2 ай бұрын
Depends on what and how you expose, there are different projects, no single rule for this.
@aimperialdesign65192 ай бұрын
@@LaravelDaily I've learned a lot from you. So, I refactor the queries. Would it be good if I'll show it in public when it will be used by the community? I'm new to web development. I'm starting to learn PHP and JS both without framework but halted due to have to rush the project. And tried Laravel based on my VB knowledge. So, I don't I actually know most of your coding style previously because I tried eloquent from the start. My controllers have bunch of codes while yours are just few lines. But still manage to made it work well and load efficient for some maybe.
@LaravelDaily2 ай бұрын
I don't really understand the question. Where do you want to show it and how? You don't need MY permission to show your code somewhere :)
@IlPandax2 ай бұрын
I really like these tips, BUT, be cautious when using "fresh" because if you have other tables in the DB you are using for your laravel tables (for whatever reason), they will ALL be deleted, not only laravel tables.
@shahsawoodshinwari2 ай бұрын
Actually i am not a fan of things to do in services instead i do that in models and have my dedicated package called Laravel trait generator which generates those traits fir me.
@chlouis-girardot2 ай бұрын
Maybe : a rule with pest arch to not allowed "all()" method on Eloquent Model ?
@LaravelDaily2 ай бұрын
But the same would apply to ->get()->where(), not only all(). But yeah, maybe something is possible to build via custom Pest arch tests.
@drewbertola2 ай бұрын
(@ 2:03) You would actually prefer this outside of the controller? Traditionally the controller is for business logic, not just a proxy for a crud model. I'd hate to go into code that buried business logic deeper because it didn't match a CRUD operation.
@LaravelDaily2 ай бұрын
Controller is for business logic? Maybe you're coming from other framework/language? In Laravel, the goal of controller is to, well, CONTROL, get the parameters, call the logic methods, return the results.
@MrDhumpАй бұрын
@@LaravelDaily correct, like in your other video I commented that "routes are meant to just.. route", likewise as the name suggests, controller purpose is to just control 😊
@Reeves_772 ай бұрын
laravel telescope
@JamesAutoDude2 ай бұрын
Personally I think all her problems would be solved with utilities lol
@ゲンスルー-g2q2 ай бұрын
It's time to kindly assert some authority as a Laravel influencer to the rookie.
@LaravelDaily2 ай бұрын
I was trying to not go with authority, rather with helping hand. And I asked Leah's permission before shooting this video.