As a non-native English speaker, I learn new words every time I watch your videos! Today I learnt the words: remiss and dichotomy. :) Thank you Aaron! Informative video as usual.
@@Soulis98 If you're coming with a PHP background, then Livewire might be easier to understand and be a better choice in some cases. If you need high interactive client side application, then using React or Vue with Inertia would be a better alternative. Inertia caught my eye few years ago with it's possibility of creating SPA-like websites with my favorite tech stack of choice: Laravel and React. And I've done multiple client projects with it successfully. Everything seems so natural, intuitive and easy to use/integrate compared to traditional way of API + SPA communication. And as a solo engineer on a project, it was a perfect choice for me. Livewire on the hand I think was a missing piece of the Laravel ecosystem. Same technique was used by Github for many years, when on some action rendering is happening on backend and html sent to the browser, instead of json. Plus you get blade syntax support out-of-box, where u can use directives like `@can` and so on. With Inertia, you have to implement that part on your own in javascript. I've been actively using both of them on my projects and all I can say, that they made my job more enjoyable and coding fun again. I love what both Jonathan and Caleb did for the ecosystem and I think both of these packages are very underrated today.
@@hakanayayes he said it in the video lol. Livewire handles every single part of the JS without writing js. All ajax requests are handled under the hood.
@@groovebird812 My understanding is that, inertia is a bridge that connects Javascript front-end to backend like, laravel django etc, while, livewire is more like a mini framework specifically designed to work with laravel to handle reactive part of front-end.
This is the best explanation I've seen for how the different layers (back end, network, front end) work together and which frameworks cover which parts. Also, love how you visualized where Livewire sits in all of this. Really well done! Thank you.
Yeah, i think the devspace is super poluted with absolutes. I always thought of tech in general as a toolkit to solve problems. I don't care which tool fits the best, i just use the one i know solves the problem the best way and try to learn new tools regularly.
@@jordixboy Yep, my mantra is "Don't get yourself bullied". If you can't work outside of a framework to get sh* done when sh*t hits the fan, you're a script kiddie and nothing else.
This is so great! You are such a good advocate for PHP. Please keep doing what you're doing! Just let people use what works for them. I've had a bit of JS burnout lately and so I've gone back to using PHP but I've gone ultra minimalist this time with zero JS on the front-end and even using a classless CSS framework that is literally just a "drop-in and forget" solution to styling. I'm using good ol' Smarty to render HTML in PHP and the resulting HTML (with zero JS and zero CSS classes) is just so incredibly pure and simple. Admittedly, you do sacrifice A LOT by not having any JS on the front-end but the simplicity is so freeing! I'm getting features done faster than I ever have before. It's awesome!
Oh god, I can't believe it. I am so happy someone popular is actually clearing up those weird concepts that FE people have smashing NEXTJS everywhere and calling it full stack
As someone who is not a professional developer (I know some JS and a little bit of React), this is such a great overview of all the different parts that make up web app development! Like pieces of a puzzle coming together. Thank you Aaron!
Aaron I am big fan of yours and want to say thanks for your efforts! I am a self taught noob doing coding for fun, and you have always given me a lot of inspiration when I watch your videos:) Have a great day!
Dev with >15 years experience. Your content is refreshing man. Both the positivity but also technical knowledge is greatly appreciated. You’re getting me a ton more interested in php and laravel. I only knew PHP from old Zend days… insane updates. Quickest tech YTer subscribe in awhile 🎉
Thanks for posting. I'm a PHP dev looking to explore something newer/cutting edge, and this helps me on the right path. Tying together Laravel and React is going to make me such a powerful developer.
I think this video really necessary today. I use Laravel 9 years already and started using React in the v15, and I see a huge hate on the Laravel community about React that I can't understand. Laravel is the most amazing framework in my opinion and I think that the power of the interaction and management of React complements this ecosystem so well.
Great video! It makes it very very easy to understand the whole eco system and describe what is what, where it belongs and what's it's role it for someone like me who is new and doesn't know what all these technologies are.
Using the term "center-stack framework" to describe recent JS frameworks is so good. I've been writing a lot of SvelteKit recently and wondered why the backend functionality seemed so sparse, even though it's often called full-stack. Definitely looking into Laravel for my next project.
I mean if I am starting a new project, I personally prefer to not to mix backend and frontend. It's always better to create an API and connecting front and back together, this way in the future you can build mobile apps using the same backend, you can hire easier since you are using mainstream tools and framework (i. e. Vue, React) instead of finding people who know edge cases. There are hundreds of reason why not to do this, but it may be a good for some edge cases.
Hey Aaron, I've been using Inertia for a few months now, and I gotta say it's a joy to work with. It's really minimal in a sense that it gives you the basic Laravel/React bridge + some pretty nice utility components, such as InertiaLink. It doesn't make you dependent on itself, like a framework would, so you're still writing React/Vue/Svelte code.
Laravel is the best ecosystem I ever experienced for building MPA. In other languages (C, Java, Js, Python, Go) I always need to glue together different 3rd party libs. I wish we had smth complete like Laravel for Java or Go.
I've never understood why? Why, if you have available all of the periphenalia in Laravel itself, would you want to add more javascript just for the sake or the snappy-ness? What is exactly wrong with "old school" approach of building web apps? I don't get it.
I personally love Livewire. It's pretty easy to start the first demo for clients. I don't have to mess up with building back-end API or fetching API in front-end. All I need is just Livewire components Of course, I also use React, Vue or sometime Angular. It depends on requirements and many other reasons. It doesn't have to be this tool or that tool. It's how we mix up and make it works for our clients!
I learned a lot from this video and gained some clarity on a problem we are currently facing with one of our projects. Our team worked on a project that uses Laravel as the API backend and Vue2/Nuxt2 as the frontend. With the release of Nuxt3, there have been significant changes, and we are struggling to decide how to keep the project updated without rewriting the entire codebase. Since all of the developers on our team are fluent in Vue.js, we still want to use it as the frontend framework. After initial discussions, we are leaning towards using Laravel + Inertia + Vue, but we are open to any other suggestions. Any input is highly appreciated.
inertia js is the key, Laravel solid backend with queues, validation, authentication, MVC, support multiple db connection it could be mysql and mongodb or etc
I think the problem sometimes in this discussion is people trying to set the "default" framework for frontend as if just React exists, ignoring Vue.js or even HTMX... Not just because it is currently the largest used that it's the best framework, just see how much jQuery reigned and how it is seen now.
We use Laravel on the back end and Vue on the front. Works pretty well. We've done it for a while. However, we are moving to fully NextJS. Why? It's reducing mental load by getting rid of PHP and only working in JS everywhere. Life is easier. We are more productive.
Inertia officially supports only Laravel and Ruby adapters (as they say in the documentation). Other adapters are community maintained. F.e. symfony adapter repo is currently archived and looking for a new maintainer.
I started a Laravel course on Udemy but recently stopped to learn React. I'm hoping to get my first dev job sometime this year, and it looks like most entry-level jobs in Canada seem to prioritize front end skills, so maybe React might be considered a more valuable skillset? Btw kudos for knowing what a false dichotomy is, did you by chance study philosophy?
It feels a bit weird to talk about “Network chasm”. This chasm exists in many places in software systems architecture: the file system, memory, socket programming, decoupled modules, args and environment varsity passed to a running program, config files, all of these are “chasms” that move from one context to another. The “network chasm” isn’t really that special.
@@aarondfrancis My comments are just social commentary on the industry perception that you highlighted in your vid. I’m just saying that it’s less of a “chasm”, and more like a “crack” or “gap” that is common and has been filled many times. “Chasm” makes it seem so big and scary, which it’s not when you really think about it.
Wasn't it so from ages? Where the backend could be able to generate initial HTML page and then serve the browser? I guess when ReactJs first came, it wanted to push "everything frontend" but nowadays realized, some stuffs are for the backstage. Sveltekit pioneered this onset and I love its implementation.
Which stack is better for making startups: vue+laravel/vue+express? Is there any difference what to pick up or the possibilities are the same with both?
Hey Aaron. Have you ever asked Taylor and others why jetstream starter kit does not ship with inertia and react? I really like having that option as well as breeze.
I’ve been developing apps in Laravel from 2015 to about a year ago. It does fill a huge need but I think the deployment picture still isn’t fully developed at least not in tandem with the JavaScript world.
Wonderful video overall but I think the default MVC Laravel diagram contradicts your definition. If frontend is code that runs on the client, then Blade is not frontend even if it is UI programming. I think MVC Laravel doesn't have a chasm, it's just that all the UI work is done through HTML responses. So that templating engine part you mentioned is actually part of the Network layer and very much the exact model of how websites used to be, hence Multi Page Applications and HyperText Transfer Protocol. You're completely correct about the rest though: with network-driven UI that doesn't reach into frontend capabilities, you can only do forms and links as far as interactivity goes, and more interactive Singe Page Applications necessitate client-side React/JavaScript.
This also goes for Next.js, Nuxt, Remix, ... They all do server-side rendering and send the HTML over the network. It's simply the most efficient way of sending HTML to a client. Since thats what the protocol was designed for in the first place.
Yep, I use a combination of Laravel and React, without making it a single page application, but instead having a react build for every module in the application, which I then link statically.
@@aarondfrancis Yeah, I have created a webpack builder that outputs multiple react builds at once, one for each module in my app. The react framework itself is a separate file, since it's shared between them and it should be cached only once. Like that I also manage to keep my bundle size small and fast per page, and the users probably don't navigate through each module all the time for everything to be loaded at once.
Great video Aaron. You explain things very clear. Since Inertia.js eliminates the whole API creation, when would you say is still recommended to use laravel as API backend only and fronted separately?
can you explain what sorts of interactivity react or vue provides that would be worth the extra setup? I'm not a FE developer, but so far I've been able to accomplish most everything I need with laravel and livewire, though still struggling with some parts. I don't know when I should consider alternatives such as react or vue with inertia and I hate having to keep learning new tech stacks when i still havent mastered Laravel itself. It'd be great if I had examples of what these tools are actually good for opposed to alternatives? Perhaps some samples of interactive components being built with the 3 systems (vue, react, livewire) to gauge speed and complexity of getting things set up?
Honestly I think you can get as far as you need to go with Livewire and a bit of Alpine. Only the most complex frontends would need Vue or React at this point
I'm almost exclusively a React dev, but followed you from the ashes of Planetscale. I am trying to understand the benefits you claim for using Laravel in addition to Next.js but I am yet see what issues it is solving. It feel more a preference bias than any actual value to me (and I am no doubt biased myself). What am I missing? For me, I always hated the MVC structure and OOP classes just breaks my brain with option paralysis. I feel so much happier and productive with Reacts more co-located and small declarative functions style of architecture .
From the ashes 😂 I think the benefit to using Laravel behind Next.js is that you get the power of auth, queues, database migrations, ORM, models, mail, cron, etc etc without having to piece together a bunch of packages in your own way. So your model layer works perfectly with your queued job layer works perfectly with your auth works perfectly... you get it!
@@aarondfrancis I think my confusion is that my stack seems to make these redundant. I am m yet to really need models, migrations, ORM, cron jobs etc. I quite like the ability to pick and choose my tooling I guess.
@@JohnBuildWebsites Thank you so much! I try not to be dogmatic! I love Laravel, but it's definitely not a requirement and there are lots of other good options
I've been developing with Laravel and Vue/React for over 4+ years now but I have to admit, I have never used Inertia. Something about it just seems hard to get into, so if there's a great (and free) course on it, I'd love to know :)
actually would be great if Laravel had some sort of RPC library to communicate with frontend, like Livewire without templating or Inertia without routing. That way you could pair Laravel with any frontend without need for specific adapters
@@aarondfrancis there is nothing ready made. we are using Next frontend, Expo mobile app with Laravel backend and sort of stitch it together with laravel data and typescript transformer by spatie, so its kinda typesafe end to end but still requires a lot of boilerplating with setting up controllers, frontend->backend fetch calls etc. basically works as proof of concept but would be nice if laravel had something that wraps it all up with nice api, would be great win for ecosystem IMO
@aarondfrancis Sounds like a concept I hacked around some time ago. const component = useComponent('edit-product) component.product.name = 'Updated value' component.save()
I am using react as my frontend and laravel as a backend but unfortunately there is no comprehensive tutorial about React and Laravel using inertia js. Jefferey have with Vue but no body with React.
Can someone elaborate more about the network part? Does laravel route while rendering blade file, can also pass data directly from database model? Or is it something else entirely?
@@aarondfrancis okay that's a good point. I'm nowadays using Nextjs with Supabase. But maybe I should try Laravel just to see what I'm missing out. I was a PHP developer in the past, maybe this can be a great way to pick it up again. Thanks for the vid 💯
Because if you use Next you will eventually need 10 SaaS subscriptions to cover it's missing backend functionalities. There's a reason you are using Supabase. Supabase is your actual backend, NextJS is just a proxy for it.
Here is my pro tip: Use Vue or React and try to use as few packages as possible. Then use Inertia with Laravel and try to only use Laravel first party packages.
one min silence for those who thinks php is a dead language..
proud to be a php laravel developer for a decade
sunken cost fallacy?
@@nymez6968 literally no
@@nymez6968 Cope
Seems to be more PHP jobs
@@Joshua.Developer more than what?
As a non-native English speaker, I learn new words every time I watch your videos!
Today I learnt the words: remiss and dichotomy. :)
Thank you Aaron! Informative video as usual.
I like you already 🤗
Remiss was a vocubulary that cought my fancy in this video. I had to look up its meaning.
Me too. He speaks very clearly.
Started a Laravel/Inertia/Vue project this week. I am still very much slower in writing php, but you can just 'feel' how powerful this stack is.
The old VILT stack. Easily my favorite.
I was an early adopter of the Inertia with React and I can really enjoy seeing this combo gaining traction again these days.
Better than livewire?
@@Soulis98 If you're coming with a PHP background, then Livewire might be easier to understand and be a better choice in some cases. If you need high interactive client side application, then using React or Vue with Inertia would be a better alternative.
Inertia caught my eye few years ago with it's possibility of creating SPA-like websites with my favorite tech stack of choice: Laravel and React. And I've done multiple client projects with it successfully. Everything seems so natural, intuitive and easy to use/integrate compared to traditional way of API + SPA communication. And as a solo engineer on a project, it was a perfect choice for me.
Livewire on the hand I think was a missing piece of the Laravel ecosystem. Same technique was used by Github for many years, when on some action rendering is happening on backend and html sent to the browser, instead of json. Plus you get blade syntax support out-of-box, where u can use directives like `@can` and so on. With Inertia, you have to implement that part on your own in javascript.
I've been actively using both of them on my projects and all I can say, that they made my job more enjoyable and coding fun again. I love what both Jonathan and Caleb did for the ecosystem and I think both of these packages are very underrated today.
Same
For a PHP developer like me who is primarily backend person; livewire is awesome! It's like writing php for front-end.
livewire is actually JS
@@hakanayayes he said it in the video lol.
Livewire handles every single part of the JS without writing js. All ajax requests are handled under the hood.
What are the differences between livewire and inertia? There are so many libs and it is difficult to find the exact boundary
@@groovebird812 My understanding is that, inertia is a bridge that connects Javascript front-end to backend like, laravel django etc, while, livewire is more like a mini framework specifically designed to work with laravel to handle reactive part of front-end.
so server components for php? :P
I'm sold, following you from planetscale though i haven't used planetscale ever.
Thank you 😍
Me too 😊
This is the best explanation I've seen for how the different layers (back end, network, front end) work together and which frameworks cover which parts.
Also, love how you visualized where Livewire sits in all of this. Really well done! Thank you.
Thank you Justin!!
I love the take of "let's stop making everything X vs Y and instead use X and Y when appropriate"
This, everytime. I wonder why people want everything to be all or nothing
thats the whole premise of being a software engineer, if you're a fanboy about a certain technology, then you're not a good software engineer.
Yeah, i think the devspace is super poluted with absolutes. I always thought of tech in general as a toolkit to solve problems. I don't care which tool fits the best, i just use the one i know solves the problem the best way and try to learn new tools regularly.
Watch me use react with laravel
@@jordixboy Yep, my mantra is "Don't get yourself bullied".
If you can't work outside of a framework to get sh* done when sh*t hits the fan, you're a script kiddie and nothing else.
This is so great! You are such a good advocate for PHP. Please keep doing what you're doing! Just let people use what works for them.
I've had a bit of JS burnout lately and so I've gone back to using PHP but I've gone ultra minimalist this time with zero JS on the front-end and even using a classless CSS framework that is literally just a "drop-in and forget" solution to styling.
I'm using good ol' Smarty to render HTML in PHP and the resulting HTML (with zero JS and zero CSS classes) is just so incredibly pure and simple.
Admittedly, you do sacrifice A LOT by not having any JS on the front-end but the simplicity is so freeing! I'm getting features done faster than I ever have before. It's awesome!
Oh god, I can't believe it. I am so happy someone popular is actually clearing up those weird concepts that FE people have smashing NEXTJS everywhere and calling it full stack
I heard there was drama on xitter about react vs Laravel. And now this! Thanks for talking sense, Aaron
🫡
In other words, all we need for Web Dev is PHP for back and JS for Front End. Like it was 20 years ago. For me, this is the perfect Mix.
As someone who is not a professional developer (I know some JS and a little bit of React), this is such a great overview of all the different parts that make up web app development! Like pieces of a puzzle coming together. Thank you Aaron!
Gosh this is such a good video. The intro made me laugh 😂
This is the content I’m here for!
Haha thank you
Aaron I am big fan of yours and want to say thanks for your efforts! I am a self taught noob doing coding for fun, and you have always given me a lot of inspiration when I watch your videos:)
Have a great day!
Thank you!
Dev with >15 years experience. Your content is refreshing man. Both the positivity but also technical knowledge is greatly appreciated. You’re getting me a ton more interested in php and laravel. I only knew PHP from old Zend days… insane updates. Quickest tech YTer subscribe in awhile 🎉
Thank you for telling me! That's an encouragement
Another great video! I’ve been using your videos to learn Laravel and your videos have made growing my application’s features much easier.
Thanks for posting. I'm a PHP dev looking to explore something newer/cutting edge, and this helps me on the right path. Tying together Laravel and React is going to make me such a powerful developer.
I think this video really necessary today. I use Laravel 9 years already and started using React in the v15, and I see a huge hate on the Laravel community about React that I can't understand. Laravel is the most amazing framework in my opinion and I think that the power of the interaction and management of React complements this ecosystem so well.
Great video! It makes it very very easy to understand the whole eco system and describe what is what, where it belongs and what's it's role it for someone like me who is new and doesn't know what all these technologies are.
With Arms Wide Open, Under ... Laravel. Welcome to this place, I'll show you everything - Aaron's Ringtone
😂 bravo
Using the term "center-stack framework" to describe recent JS frameworks is so good. I've been writing a lot of SvelteKit recently and wondered why the backend functionality seemed so sparse, even though it's often called full-stack. Definitely looking into Laravel for my next project.
This aligns with my favourite approach exactly! Laravel inertia and Vue are a powerhouse for full stack development!
Really enjoy the graphics. Nice step up in quality!
Thanks! That's all my cofounder, Producer Steve. He's the wizard
Thank you for your videos! People like you reassure me that php/laravel is awesome and leave the haters be
This is THE BEST visualization for making the right choice!!!
I mean if I am starting a new project, I personally prefer to not to mix backend and frontend. It's always better to create an API and connecting front and back together, this way in the future you can build mobile apps using the same backend, you can hire easier since you are using mainstream tools and framework (i. e. Vue, React) instead of finding people who know edge cases. There are hundreds of reason why not to do this, but it may be a good for some edge cases.
Hey Aaron, I've been using Inertia for a few months now, and I gotta say it's a joy to work with. It's really minimal in a sense that it gives you the basic Laravel/React bridge + some pretty nice utility components, such as InertiaLink. It doesn't make you dependent on itself, like a framework would, so you're still writing React/Vue/Svelte code.
love using inertia with vue
Laravel + Next.js = 🤯
30 seconds into the video and you earned a Like
😮💨😮💨 thank you
I have been using inertia with react and laravel.
Great right?
I have been using inertia with vue and laravel
Laravel is the best ecosystem I ever experienced for building MPA. In other languages (C, Java, Js, Python, Go) I always need to glue together different 3rd party libs. I wish we had smth complete like Laravel for Java or Go.
In my opinion, inertia joins the most powerful backend framework with the most powerful frontend library.
thanks for explaining fundamentally i loved the format thank you
Never heard the word "Chasm" that many times within a few minutes
I've never understood why? Why, if you have available all of the periphenalia in Laravel itself, would you want to add more javascript just for the sake or the snappy-ness? What is exactly wrong with "old school" approach of building web apps? I don't get it.
Amazing! Imagine telling a team that’s used to doing express api’s for frontends about this 😂
Hahahaha nice intro, the thumbnail had me thinking "what about Laravel & React"
About time we got some props for Laravel + JS
Laravel is still very much slept on by a large chunk of the dev community. We use it explicitly, big web apps, its great.
Very informative on stuff I already did know but someone that is fresh to this it's a valuable video
I personally love Livewire.
It's pretty easy to start the first demo for clients.
I don't have to mess up with building back-end API or fetching API in front-end.
All I need is just Livewire components
Of course, I also use React, Vue or sometime Angular. It depends on requirements and many other reasons.
It doesn't have to be this tool or that tool. It's how we mix up and make it works for our clients!
I'm 43 yrs, i'v been started learning php to learn laraval , hopefully to find a job as developper
I learned a lot from this video and gained some clarity on a problem we are currently facing with one of our projects. Our team worked on a project that uses Laravel as the API backend and Vue2/Nuxt2 as the frontend. With the release of Nuxt3, there have been significant changes, and we are struggling to decide how to keep the project updated without rewriting the entire codebase. Since all of the developers on our team are fluent in Vue.js, we still want to use it as the frontend framework. After initial discussions, we are leaning towards using Laravel + Inertia + Vue, but we are open to any other suggestions. Any input is highly appreciated.
so i must use both, thanks for clearing.
You're welcome! Glad it was helpful
Livewire for the win.
inertia js is the key, Laravel solid backend with queues, validation, authentication, MVC, support multiple db connection it could be mysql and mongodb or etc
I really love your videos! Hopefully you post more content for us to learn
Happy with Next.js full stack.✨✨
Great! I'm happy for you
Great explanation. Keep up the good work.
Been using react and Laravel a lot lately but been a little disappointed at the lack of adoption of it. Glad to see that slowly changing!
I think the problem sometimes in this discussion is people trying to set the "default" framework for frontend as if just React exists, ignoring Vue.js or even HTMX...
Not just because it is currently the largest used that it's the best framework, just see how much jQuery reigned and how it is seen now.
We use Laravel on the back end and Vue on the front. Works pretty well. We've done it for a while.
However, we are moving to fully NextJS.
Why?
It's reducing mental load by getting rid of PHP and only working in JS everywhere.
Life is easier. We are more productive.
Holy moly. I use Payload CMS ( build on Nextjs) with a MongoDB and a Nextjs Frontend - done.
Cool!
Thank you sir ❤❤
do you have any course for using laravel, inertia and vue.js???
This is exactly what im looking for 🔥
nice and fluent explanation, thank you so much
Already have a running Laravel and vue. I will try later the react
Inertia officially supports only Laravel and Ruby adapters (as they say in the documentation). Other adapters are community maintained. F.e. symfony adapter repo is currently archived and looking for a new maintainer.
They don't say they have adapter for django, but have a interia-django repo on their github account - that's odd
Huh that is interesting. I wonder if the docs are just outdated for that section
I started a Laravel course on Udemy but recently stopped to learn React. I'm hoping to get my first dev job sometime this year, and it looks like most entry-level jobs in Canada seem to prioritize front end skills, so maybe React might be considered a more valuable skillset?
Btw kudos for knowing what a false dichotomy is, did you by chance study philosophy?
It feels a bit weird to talk about “Network chasm”. This chasm exists in many places in software systems architecture: the file system, memory, socket programming, decoupled modules, args and environment varsity passed to a running program, config files, all of these are “chasms” that move from one context to another. The “network chasm” isn’t really that special.
One can only cover so many chasms per video. And only the network chasm was relevant
@@aarondfrancis My comments are just social commentary on the industry perception that you highlighted in your vid. I’m just saying that it’s less of a “chasm”, and more like a “crack” or “gap” that is common and has been filled many times. “Chasm” makes it seem so big and scary, which it’s not when you really think about it.
Wasn't it so from ages? Where the backend could be able to generate initial HTML page and then serve the browser?
I guess when ReactJs first came, it wanted to push "everything frontend" but nowadays realized, some stuffs are for the backstage.
Sveltekit pioneered this onset and I love its implementation.
I'm about to level up from WordPress to Laravel for my next project
The video started with really awesome conversation until the phone call cut it.. love to hear the rest :))
😉
Which stack is better for making startups: vue+laravel/vue+express? Is there any difference what to pick up or the possibilities are the same with both?
Express is just a router. Laravel is a full stack framework
Hey Aaron. Have you ever asked Taylor and others why jetstream starter kit does not ship with inertia and react? I really like having that option as well as breeze.
I haven't! I'm sure it just doesn't line up with what they personally use. Just a guess though
nice one, love this type of videos 😁 love the overview that invite you to investigate ❤
Great video, couldn't agree more!
Mr. Dunphy comes for the rescue ❤
Everyone's favorite sitcom / youtube dad
I’ve been developing apps in Laravel from 2015 to about a year ago. It does fill a huge need but I think the deployment picture still isn’t fully developed at least not in tandem with the JavaScript world.
Wonderful video overall but I think the default MVC Laravel diagram contradicts your definition. If frontend is code that runs on the client, then Blade is not frontend even if it is UI programming. I think MVC Laravel doesn't have a chasm, it's just that all the UI work is done through HTML responses. So that templating engine part you mentioned is actually part of the Network layer and very much the exact model of how websites used to be, hence Multi Page Applications and HyperText Transfer Protocol. You're completely correct about the rest though: with network-driven UI that doesn't reach into frontend capabilities, you can only do forms and links as far as interactivity goes, and more interactive Singe Page Applications necessitate client-side React/JavaScript.
This also goes for Next.js, Nuxt, Remix, ... They all do server-side rendering and send the HTML over the network. It's simply the most efficient way of sending HTML to a client. Since thats what the protocol was designed for in the first place.
Sick. Might get the opportunity to make a new application for a client soon, and I think we'll probably try this.
Yep, I use a combination of Laravel and React, without making it a single page application, but instead having a react build for every module in the application, which I then link statically.
Ooo interesting
@@aarondfrancis Yeah, I have created a webpack builder that outputs multiple react builds at once, one for each module in my app. The react framework itself is a separate file, since it's shared between them and it should be cached only once.
Like that I also manage to keep my bundle size small and fast per page, and the users probably don't navigate through each module all the time for everything to be loaded at once.
Incredible explanation 👏
Great video Aaron. You explain things very clear. Since Inertia.js eliminates the whole API creation, when would you say is still recommended to use laravel as API backend only and fronted separately?
If you were using Next or Nuxt or needed an API for other reasons beyond your own frontend
Laravel + Inertia + Vue js 3 are the best for me
Another great video. Thank you!
can you explain what sorts of interactivity react or vue provides that would be worth the extra setup? I'm not a FE developer, but so far I've been able to accomplish most everything I need with laravel and livewire, though still struggling with some parts. I don't know when I should consider alternatives such as react or vue with inertia and I hate having to keep learning new tech stacks when i still havent mastered Laravel itself. It'd be great if I had examples of what these tools are actually good for opposed to alternatives? Perhaps some samples of interactive components being built with the 3 systems (vue, react, livewire) to gauge speed and complexity of getting things set up?
Honestly I think you can get as far as you need to go with Livewire and a bit of Alpine. Only the most complex frontends would need Vue or React at this point
Is it sort of like Nuxt?
I'm almost exclusively a React dev, but followed you from the ashes of Planetscale. I am trying to understand the benefits you claim for using Laravel in addition to Next.js but I am yet see what issues it is solving. It feel more a preference bias than any actual value to me (and I am no doubt biased myself). What am I missing?
For me, I always hated the MVC structure and OOP classes just breaks my brain with option paralysis. I feel so much happier and productive with Reacts more co-located and small declarative functions style of architecture .
From the ashes 😂 I think the benefit to using Laravel behind Next.js is that you get the power of auth, queues, database migrations, ORM, models, mail, cron, etc etc without having to piece together a bunch of packages in your own way. So your model layer works perfectly with your queued job layer works perfectly with your auth works perfectly... you get it!
@@aarondfrancis I think my confusion is that my stack seems to make these redundant. I am m yet to really need models, migrations, ORM, cron jobs etc. I quite like the ability to pick and choose my tooling I guess.
@@JohnBuildWebsites That's great! Then Laravel might not be for you
@@aarondfrancis Appreciate the candid response. Looking forward to seeing your future content for tools I do use, as really love the way you teach!
@@JohnBuildWebsites Thank you so much! I try not to be dogmatic! I love Laravel, but it's definitely not a requirement and there are lots of other good options
I've been developing with Laravel and Vue/React for over 4+ years now but I have to admit, I have never used Inertia. Something about it just seems hard to get into, so if there's a great (and free) course on it, I'd love to know :)
I only know of Laracasts!
I feel this debates depend on tons of factors. Your heart might say Laravel, your mind might say React due to the job market.
That's fine! React works great with Laravel
HTMX mentioned!
actually would be great if Laravel had some sort of RPC library to communicate with frontend, like Livewire without templating or Inertia without routing. That way you could pair Laravel with any frontend without need for specific adapters
Hmmm that's an interesting idea. Do you know of any prior art here?
@@aarondfrancis there is nothing ready made. we are using Next frontend, Expo mobile app with Laravel backend and sort of stitch it together with laravel data and typescript transformer by spatie, so its kinda typesafe end to end but still requires a lot of boilerplating with setting up controllers, frontend->backend fetch calls etc.
basically works as proof of concept but would be nice if laravel had something that wraps it all up with nice api, would be great win for ecosystem IMO
@@msnegurski Extremely interesting... I'll see if I can wrap my head around it!
@aarondfrancis Sounds like a concept I hacked around some time ago.
const component = useComponent('edit-product)
component.product.name = 'Updated value'
component.save()
Please make A video about LARAVEL+HTMX supremacy
I am using react as my frontend and laravel as a backend but unfortunately there is no comprehensive tutorial about React and Laravel using inertia js. Jefferey have with Vue but no body with React.
At this point, everything seems better than react
Can someone elaborate more about the network part? Does laravel route while rendering blade file, can also pass data directly from database model? Or is it something else entirely?
I had my ReactJS, Redux, Axios, Laravel (REXAL STACK) but I would love to go this one VILT STACK OR RILT STACK OR NILT stack
There’s some really old issues on the inertia github repo that are seemingly ignored. I wouldn’t want to start a new project with it.
This guy wants end the backend-frontend war
God willing
HTMX mentioned, lets go!
I wish Django had that
Django has Unicorn. And you can use inertia with Django.
Great video 👍
Wait a minute, Livewire works with htmx? (Edit: I was wrong)
I have been doing htmx and blade, with a tiny bit of Alpine. Love it.
Ah sorry, no. Livewire is *like* HTMX, Liveview, etc.
@@aarondfrancis I misheard that, no worry. Thanks! I love htmx a lot.
219 views in 8 minutes, he fell off...
Edit: /s
Thanks for this awesome content Aaron!
Is that good or bad? I don't understand. I feel like it's good!
@@aarondfrancis Better see a million views in 30 seconds next time, bud.
(I'm kidding. It's awesome! Love your content brother, please keep it up!)
Nextjs can be used as a backed and front-end. I don't see why you need an extra backend
Database, auth, queues, ORM, mail, cron, console commands, etc etc etc
@@aarondfrancis okay that's a good point. I'm nowadays using Nextjs with Supabase. But maybe I should try Laravel just to see what I'm missing out. I was a PHP developer in the past, maybe this can be a great way to pick it up again. Thanks for the vid 💯
Because if you use Next you will eventually need 10 SaaS subscriptions to cover it's missing backend functionalities. There's a reason you are using Supabase. Supabase is your actual backend, NextJS is just a proxy for it.
Here is my pro tip: Use Vue or React and try to use as few packages as possible. Then use Inertia with Laravel and try to only use Laravel first party packages.
This is a good tip! 🫡
php backend framework vs js frontend library... what? next video bugatti vs fanta?
Ooo good idea. Just gotta get my hands on a bugatti