Inertia 2.0: It's like Next but better (and you can use React!)

Поділитися
Вставка
  • Опубліковано 21 січ 2025

КОМЕНТАРІ • 238

  • @vikkio88
    @vikkio88 16 днів тому +288

    we are back to square one, php.
    Now let's wait for someone to reinvent SPA

    • @RafaelBelvederese
      @RafaelBelvederese 16 днів тому

      yes, but no.

    • @wilsenhc
      @wilsenhc 16 днів тому +10

      Inertia.js is already SPA and SSR capable at the same time

    • @dogoku
      @dogoku 16 днів тому +14

      The best mental model for the current trend of web development, is a spiral. We are not going in circles, we are moving upwards along a spiral staircase.
      Meaning that while we are going back to server side rendering, we are also a lot more clever about how we do it and its vastly different from what we had in the past.

    • @muraliavarma
      @muraliavarma 16 днів тому +2

      @@dogoku Such a nice way of putting it! I can see why people can think of this as "hey we are making the same mistakes over and over", but it is clear that we went through various stages of evolution before ending up where we are. A lot of smart people think about this every single day to make incremental progress. On hindsight we can see how PHP from the 2000s got a lot of it right but imo the only piece that was missing was the interactivity and that is where jQuery came in. To me, we had to go through a lot of stages to get that fixed up, and it has not been simple, but we are clearly in a better place than where we were 15 years ago. My 2 cents...

    • @hannad
      @hannad 16 днів тому +1

      I blame the influencers 💰💰

  • @dogoku
    @dogoku 16 днів тому +35

    12:00 If I am not mistaken, in .NET Blazor you can use simple logic (e.g if statement) to render a loading state and it will do a partial render and update via the websocket when ready
    @if (data == null) {
    Loading...
    } else {
    @data
    }

    • @IvanRandomDude
      @IvanRandomDude 16 днів тому +7

      You can but you need to enable streaming rendering. Otherwise the rendering will wait for async task to complete and then check the condition.

    • @heckintosh2994
      @heckintosh2994 16 днів тому +2

      Effectively, this is what Inertia also does on the SSR side of things.

  • @itsTarik
    @itsTarik 16 днів тому +50

    4:17 inertia is available on rails and some other frameworks via community package

    • @Nat-ih9oe
      @Nat-ih9oe 16 днів тому +7

      It is still a community project, for now Laravel is the only official backend supported by Inertia.

    • @gcash49
      @gcash49 16 днів тому +2

      aint no serious project gonna use that community package

    • @ceigey-au
      @ceigey-au 16 днів тому +3

      AdonisJS maintains their own adapter which is pretty cool of them. Other Node/WinterCG server frameworks, not so much :(

    • @shining_cross
      @shining_cross 16 днів тому

      ​@@gcash49why? laravel is also community package, livewire is also community package, etc etc. go inertia is more than 10x faster than laravel inertia, less buggy, easy to create concurrent program, many libraries, easy syntax not like php bad syntax, etc

    • @paolo-e-basta
      @paolo-e-basta 16 днів тому +1

      It's unfortunate that they are not officially supported. I use Django for ages and it's fine for what I'm doing, but the Django adapter lags behind and the adapter development is very slow. I wish I have more skills (or money) to fix this situation

  • @DullJoker
    @DullJoker 15 днів тому +4

    Really dope to see where Laravel and Inertia is going throughout the years! It’s starting to look so much better than what I’ve had to experience using it during my collage journey. 🎉

  • @alexenriquecrispim830
    @alexenriquecrispim830 13 днів тому +4

    Nice to see you talk about Inertia. I have plans to write an adapter for Django soon, because the existing one is a bit abandoned and not so good. I really beliave in Inertia.

  • @darkoplax7688
    @darkoplax7688 16 днів тому +157

    wasn't the whole point of using JS in the server so you have your frontend and backend in the same language ... idk why would I ever do php or python; might as well use Java, C# or Go for better performance

    • @SiddharthPant
      @SiddharthPant 16 днів тому +40

      Same as Apple devices, its about ecosystem. Like checkout Laravel Queues documentation it goes on and on with features and ease of use. And then there are other tools in the ecosystem like Pulse, Horizon, Socialite etc. all first party supported. Tired of that then there are spatie packages. Also PHP is not slow, in raw benchmarks if something takes 30ms in Go it would usually take 70-100ms in PHP vs 400+ ms in Python. In real backends the difference with Go vs PHP should be even lower due to I/O bottlenecks.

    • @infiniteone783
      @infiniteone783 16 днів тому +22

      Java for better performance? No pls

    • @darkoplax7688
      @darkoplax7688 16 днів тому +28

      @@infiniteone783 I mean as much we all hate java it still performs better than interpreted languages

    • @darkoplax7688
      @darkoplax7688 16 днів тому +1

      @@SiddharthPant But if it's about ecosystem, wouldn't you rather GET what's in phpland to JSland rather than go there yourself ... like I would prefer Next or Remix or React Router to implement those inertia innovations rather than use inertia itself

    • @infiniteone783
      @infiniteone783 16 днів тому +2

      @@darkoplax7688 I can't tell if you're referring to Java or JavaScript. NodeJS is far superior in terms of speed than Java. Go would be even better.

  • @RillonDodgers
    @RillonDodgers 16 днів тому +20

    Inertia is also really fun to use with Rails

  • @nyzss
    @nyzss 16 днів тому +37

    9:18 he said the thing

  • @SpaceGhost-1999
    @SpaceGhost-1999 16 днів тому +27

    ‘Our front ends need to know more about our back ends, and our back ends need to know more about our front ends’ - next thing you know, Theo will invent ‘MVC’. Let me introduce you to this cool new language, its name is “Smalltalk”.

    • @NathanBudd
      @NathanBudd 15 днів тому

      Wait until you hear about Laravel Livewire...

  • @IvanRandomDude
    @IvanRandomDude 16 днів тому +22

    12:10 Blazor (Stream rendering)

  • @ChristophFloat
    @ChristophFloat 16 днів тому +16

    3:22 Huh?? It's been a while since I developed with PHP (and Laravel) professionally, but I swear, passing data between the BE and FE worked exactly the same way 6 years ago.

    • @ar1i_k
      @ar1i_k 16 днів тому +4

      You passed this to php server side layer. If you wanted to have the same data on client side JavaScript you needed to also create an API endpoint to hit it manually with a fetch request.
      Inertia streamlines boilerplate generation and makes passing data to JavaScript frameworks as effortless, as passing it to php blade templates

    • @ar1i_k
      @ar1i_k 16 днів тому +3

      Key here is that we are passing all the php data not to .blade.php file but to .Vue / .tsx file which feels kinda magical!

    • @ChristophFloat
      @ChristophFloat 16 днів тому +3

      @@ar1i_k I get that, but again, I could have sworn that I watched a Laracasts episode about 6 or 7 years ago where Jeffrey did this exact thing, passing data between a Laravel BE and a Vue SPA FE. But maybe back then, it was some sort of "hack" and now it's a finished product? Or maybe I'm misremembering completely, that is also a possibility of course.

    • @ar1i_k
      @ar1i_k 16 днів тому +3

      @@ChristophFloat ahhhh…
      No inertia existed even then, sorry for misunderstanding.
      It’s just wasn’t as versatile and feature-complete solution (like Theo mentioned - “good luck with polling or infinite scrolling”) so most people didn’t bother adding a layer of complexity “to avoid writing api endpoints” when we still would need to write them anyway.
      Now that Inertia 2.0 removed most of the old pain points, we may actually use it “to avoid writing api endpoints” and it finally looks like a good default option for Laravel devs (and absolute magic for outside observers like Theo)

    • @bartek.igielski
      @bartek.igielski 16 днів тому +2

      back then Vue was used kinda like Alpine.js or HTMX is today, as a sparkle on top of server side generated HTML to handle client side interactions

  • @hamburger--fries
    @hamburger--fries 16 днів тому +6

    I used it on a Wordpress project as well. It allows you to make ReactJS plugins with almost zero php, other than boilerplate php.

    • @mkdidit-t2v
      @mkdidit-t2v 16 днів тому

      bro you used this "boxybird/inertia-wordpress" or there was another way around it ??

    • @MrJfergs
      @MrJfergs 16 днів тому

      When you say React plugins do you mean like the UI of a Wordpress plugin? I know you are able to use react for Gutenberg blocks but I wasn’t aware that you could use them for the plugins themselves.

    • @hamburger--fries
      @hamburger--fries 16 днів тому +1

      @@MrJfergs I make a complete Wordpress plugin using ReactJS/TS/Tailwind + InetiaJS-2.0 with Tanstack State + Tanstack Query + Websocket I used some other packages but forgot exactly. But you run it with a special Wordpress build tool provided by Wordpress. But the end result is you can build using 99% ReactJS and InertiaJS allows you to not have to do a bunch of complex API coding.

    • @hamburger--fries
      @hamburger--fries 16 днів тому

      @@MrJfergs As ChatGPT 4o how to do it. Ask a few different ways and then you can do things in Visual Studio Code. I use a Hyper-V VM with Fedora and NGINX, PHP, Node, etc. so I can have a very fun and fast coding experience.

    • @devdance95
      @devdance95 14 днів тому

      @@hamburger--fries Hi, Would you please share source code ? I want to see how to code with InertiaJS in WordPress ecosystem.

  • @Twst3628
    @Twst3628 8 днів тому +1

    Inertia has typescript support, I built my entire project in inertia js + typescript+ react + laravel

  • @zebraforceone
    @zebraforceone 16 днів тому +3

    Inertia is ridiculously good, I've used it in many projects now

  • @slickwit8762
    @slickwit8762 12 днів тому

    Ive been using inertia v1 for a year now and i feel in love with laravel as a react dev
    v2 is amazing wow

  • @rajeshpandey751
    @rajeshpandey751 16 днів тому +88

    Congrats, You just discovered Sveltekit data loading pattern and form actions

    • @predaytor
      @predaytor 16 днів тому +4

      Thx but I rather stick with Remix (React Router)

    • @ro0t3ntry
      @ro0t3ntry 16 днів тому +1

      @@predaytor FR remix is so underrated

    • @aghileslounis
      @aghileslounis 16 днів тому +1

      You have no clue, it looks the same but it isn't 😆

    • @moarjank
      @moarjank 15 днів тому +2

      Inertia supports svelte, Vue and others too

  • @haveboard
    @haveboard 15 днів тому +1

    I hesistated watching this video because youyr face made me think you were gonna bag on it taking a dig at NextJS. great video!

  • @BorisBarroso
    @BorisBarroso 16 днів тому +3

    Theo you need to dig a bit more into Phoenix/Liveview 😄 but you can also use inertia with it so you have the best of both.

  • @SpaceGhost-1999
    @SpaceGhost-1999 16 днів тому +4

    lol. Dissing Rails while I’ve been using Inertia in Rails for months

  • @jonathanjensen9147
    @jonathanjensen9147 16 днів тому +2

    Wondering how the API peeps feel about the responsibility bloat - There’s a decent chunk of client-side responsibility being allocated to the API - stuff that’s usually pretty UX driven. Getting that much closer to the end user means taking on UX concerns and a chunk of client side architecture - quite a different thought process especially given the traditional separation of concerns

    • @yojou3695
      @yojou3695 16 днів тому

      "traditional separation of concerns" is doing some heavy lifting here. Separation between backend and frontend is still a relatively new thing

    • @jonathanjensen9147
      @jonathanjensen9147 15 днів тому

      ​@@yojou3695 10+ years at the pace tech moves - and you could argue thats conservative.

  • @IvanRandomDude
    @IvanRandomDude 16 днів тому +22

    I wish Go community was more invested into Intertia instead of something like templ lmao

    • @User948Z7Z-w7n
      @User948Z7Z-w7n 16 днів тому

      Inertia is 36k loc. It's too small to be framework. Which means you'll end up importing 3rd party tools a lot. It's another premature hype in JS world

    • @benbowers3613
      @benbowers3613 16 днів тому

      Wrong way to look at it imho. If you are using Go as your webserver, it should be _because_ you want to use a mostly _buildless_ frontend like alpine-ajax or htmx (because you want to escape serverless hell and use your own VPS).
      If you want to use modern JS frameworks, they are unfortunately largely tied to having JS be the backend specifically for _rendering._
      Alternatively, you can let NextJS do its rendering with JS regularly and then use Go ONLY for your REST API, thus a "hybrid" solution.

    • @User948Z7Z-w7n
      @User948Z7Z-w7n 16 днів тому

      @@benbowers3613 2nd approach is the way to go. 1st approach would work for websites with weak UI game

  • @moarjank
    @moarjank 15 днів тому

    I just like that they let you pick so many backends and so many frontends. Svelte plus Django is awesome.

  • @dennisalbert6115
    @dennisalbert6115 15 днів тому +2

    use php for api and server side programs and react for UI/UX

  • @tom.watkins
    @tom.watkins 15 днів тому +1

    Isn't passing promises (instead of awaiting them) from RSC's and using the new use hook more or less the same as the defferred stuff? Still nice tho

  • @oluijks
    @oluijks 16 днів тому +2

    In 20 years from now, it will be a bit different. The (js) client will tell the server what to create/generate

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      I mean, it's already like that, it all starts with a request from the client asking the server to provide something

  • @DeVontaeMoore-wb6gw
    @DeVontaeMoore-wb6gw 11 днів тому

    The benefits are enticing. But I've also heard arguments against Inertia.
    In the spirit of Proverbs 18:17, I'm curious if anyone with inertia experience has a rebuttal to these claims I've seen online:
    1. Inertia doesn't work with large teams
    2. Bigger teams benefit from split code bases
    3. Inertia means all your devs have to be "Full Stack"

  • @sillvvasensei
    @sillvvasensei 16 днів тому +5

    The only thing I'm curious about is the type safety story.

    • @davidrempel433
      @davidrempel433 16 днів тому +1

      There's no story to tell 😂

    • @davidrempel433
      @davidrempel433 16 днів тому

      But that is one thing AI does quite well which generate all the types and type checking code

    • @paolo-e-basta
      @paolo-e-basta 14 днів тому

      In python you have a thing called pydantic. You can model your application using it and from there generate typescript types you use on the frontend. It's surely not "the final solution" but worked pretty well for me. Probably other languages have similar libs

  • @fadhilinjagi1090
    @fadhilinjagi1090 16 днів тому +8

    Adonis js + Inertia is worth looking into

    • @heckintosh2994
      @heckintosh2994 16 днів тому

      Screw Adonis.
      Adonis is a Laravel copy that has no chance of ever really being good, as they've barely have the experience and/or knowledge as to understand why Laravel does things the way they do, and instead they just copied it verbatim and went from there, and it makes sense why: They liked Laravel, but want it in JS.
      It's a great compliment to Laravel sure but it's terrible decision making. Just use Laravel and PHP, or use another actually-native JS framework and contribute any missing Laravel features to that.

    • @fadhilinjagi1090
      @fadhilinjagi1090 15 днів тому

      @@heckintosh2994 Could you explain how it has shown "terrible decision making", objectively please? It is my understanding that it borrows from not only Laravel but also Rails and Django.

    • @apisaga
      @apisaga 14 днів тому

      S7

  • @marty0678
    @marty0678 2 дні тому

    We are trying to move off Inertia because of how limiting it is at work. It's great for small/inflexible apps but it quickly becomes unwieldly as you scale.

  • @denissorn
    @denissorn 16 днів тому

    APIs are versatile and most serious application can profit from them. Alternative, to write two or more backend applications doesn't sound like fun to me.

  • @asyncrohan
    @asyncrohan 16 днів тому +13

    Why biased with react native why so many things for react but not for react native 😅

  • @Biff.future
    @Biff.future 16 днів тому +2

    People that didn’t work through the exhaustion of the 2010-2020 front end framework churn be like, “let’s do more frameworks! I hate other devs!!”

  • @AlexanderBelov-y8o
    @AlexanderBelov-y8o 16 днів тому

    Now I know what I'll be doing on the weekend!

    • @grunghi
      @grunghi 16 днів тому

      I would really recommend trying sveltekit first, it does all the things stated in the video but without needing to have a hybrid php / js stack.

  • @Skillsftwlol
    @Skillsftwlol 16 днів тому +4

    Late night theo post

  • @amirhmahmoodi4607
    @amirhmahmoodi4607 14 днів тому

    That's awesome🎉🎉🎉, using a js front end library should not force me to fetch my data only via the wire, it should not be opinionated about the data fetching mechanism

  • @SPAHI43
    @SPAHI43 15 днів тому

    I'm just curious, why in 2025 you don't have type safety? They could add some types generation. That's why Next/Astro are good, all your server actions return type is defined

  • @oddfeeling7956
    @oddfeeling7956 16 днів тому +6

    Worked at a company with 2 teams, Laravel and React. I once had to make some from end changes as the average react dev is better at front end than a laravel developer (In my experience). It was hell setting up my machine to run laravel. I see what you did with the terminal commands and all. Nice stuff really!
    And btw I still await folders on uploadthing. PLEASE WHEN FOLDERS???

    • @nicolas_vl
      @nicolas_vl 16 днів тому +3

      Do you mean you could not install PHP and Composer?? Because Laravel does not require any runtime or special configuration.
      It was always a one liner to install and one command to serve.
      Installing PHP and composer can be done in docker, in local environment, with HomeBrew or even install Laravel Herd which is a manager for laravel apps and it installs/configures everything automatically.

    • @oddfeeling7956
      @oddfeeling7956 16 днів тому

      @@nicolas_vl Wasn't so much the installation but the getting everything to work together part. Maybe easier to set up a project from scratch, but puling one wasn't the DX I was expecting. Got it to work, but it was a hassle

    • @dealloc
      @dealloc 16 днів тому +4

      @@oddfeeling7956 Docker and documentation is your answer for reproducible dev environments.

    • @oddfeeling7956
      @oddfeeling7956 16 днів тому

      @@dealloc 😂 Well not using docker wasn’t my fault now was it?

    • @dealloc
      @dealloc 16 днів тому +1

      @@oddfeeling7956 I don't know? But after you set up your environment, you could have spent time setting it up for future developers.
      Be the change you want.

  • @hunterb6907
    @hunterb6907 16 днів тому +1

    Has been multi framework, even before 2.0.

  • @pavelsheiman2962
    @pavelsheiman2962 16 днів тому +2

    Hey, have you f'd around with AdinisJS? It has an inertia adater, so we can use actual js on both backend and frontend with all typesafety and goodies it brings to the table.

    • @heckintosh2994
      @heckintosh2994 16 днів тому

      Don't do JS on the back-end. It's terrible for that.

    • @pavelsheiman2962
      @pavelsheiman2962 16 днів тому

      @ says who?

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      @@heckintosh2994 lmao have you been out of web dev for the last decade? Literally everyone and their mom uses js in the backend, even all the top 10 companies in the world that have millions to make their website shine use nodejs, there must be a reason dont you think?

  • @heyyedwin
    @heyyedwin 16 днів тому

    Theo is doing great.

  • @SulagnoGhosh
    @SulagnoGhosh 16 днів тому +5

    last time I was this early covid was still on

    • @nyzss
      @nyzss 16 днів тому

      well, HMPV is the new trend these days. history repeats itself

  • @cauthrim4298
    @cauthrim4298 16 днів тому +2

    With every new js framework we stray further from god

    • @edism
      @edism 15 днів тому +1

      Both are imaginary, there is no framework here. Protocol you mean.

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      this is more a meta framework, it isn't a javascript framework

  • @matthieu875
    @matthieu875 16 днів тому +1

    you should try inertia with adonisjs and react

  • @sergioengineer
    @sergioengineer 16 днів тому +6

    It is difficult to justify migrating from one interpreted language(TS) to another(PHP) on the backend.
    Specially so if you consider that typescript's typing is more advanced than PHP's.
    I've used laravel before. It is an awesome framework and a lot of thought has gone into it. but it is held back by PHP.
    When you weight all the variables, there are just disadvantages of using Laravel over any node solution. If I'm moving away from the JS land, then I'd probably pick go, rust, C# or any other compiled language way before ever considering PHP as an option.

    • @ceigey-au
      @ceigey-au 16 днів тому

      AdonisJS have their own official adaptor for it too (that apparently has Inertia 2.0 support). Of course that's a degree of separation from the OG Inertia implementation but might be worth a shot if you wanna stick with Node and you're happy with a typical 12-factor app deployment (vs e.g. serverless).
      From what I can see there's also a few outdated generic Node, Express and Hono adapters but they're all about 2+ years old, unfortunately.

    • @yolo-mb4cy
      @yolo-mb4cy 16 днів тому

      How likely do you think it is that Static Typing will be integrated anytime soon? for example with PHPStan

    • @moarjank
      @moarjank 15 днів тому

      It supports multiple backends, and supports Django.

  • @joaobibiano
    @joaobibiano 14 днів тому

    Oh, they discovered MVC.

  • @lutfiikbalmajid
    @lutfiikbalmajid 16 днів тому +11

    Full JS ecosystem is much simpler and faster. Even you can build binary with bun, and move it to docker with distroless image

    • @onça_pintuda999
      @onça_pintuda999 16 днів тому +3

      Oh yeah, for a TODO app for sure.

    • @edism
      @edism 15 днів тому +3

      This is either sarcasm or cluelessness.

  • @TheNightquaker
    @TheNightquaker 16 днів тому +8

    Last time I was this early Theo still knew his stuff

  • @armanamini1450
    @armanamini1450 15 днів тому

    And I don't say it because it's PHP, it's clear because you're complimenting things you'd usually hate

  • @falconiere
    @falconiere 15 днів тому

    In my time (oh boy, I am getting old), that approach would be so much over-engineer 😂😅

  • @senkai6928
    @senkai6928 14 днів тому

    adonis & inertia = perfect

  • @eyobtilahun2488
    @eyobtilahun2488 14 днів тому

    when it comes to Backend PHP is still the best!

  • @Nightlurk
    @Nightlurk 16 днів тому +1

    GenZs are discovering template parsing!

    • @moarjank
      @moarjank 15 днів тому

      Template parsing leads to script injection. SSR Vue, svelte or react (which Inertia supports) doesn't have that problem, since it's context aware. This is the #1 reason I stopped using php

  • @paulorumor6881
    @paulorumor6881 16 днів тому +4

    here we go again...... cmon now

    • @mehdi-idham
      @mehdi-idham 16 днів тому +3

      This man will say whatever you want him to say as long as you give him money $$$

    • @edism
      @edism 15 днів тому +1

      Think for once, stop parroting.

  • @sanusbenefits6327
    @sanusbenefits6327 16 днів тому

    I dont even like using LaRavel because it adds to much redundancy to my projects. I like using their templating and routing so I choose the parts I like via Composer. I will look into this in the future but again I follow the KISS principals. (Keep It Simple Stupid)

  • @GreenPixel00
    @GreenPixel00 16 днів тому

    I think Tanstack Start can handle lots of this stuff too

  • @kwyaza
    @kwyaza 16 днів тому

    Strange, User::all() is dangerous if not careful, it can expose sensitive fields in json

    • @ar1i_k
      @ar1i_k 16 днів тому

      That’s why by default Laravel creates two layers protection on user model
      ‘’’php
      protected $hidden = [“password”];
      protected $casts = [“password” => “encrypted”];
      ‘’’
      Where $hidden prevents password field from being serialised.
      And “encrypted” cast, encrypts password when you write it into object in memory (way before writing it into db) and decrypts only when accessing password manually. If hackers gets the memory dump of a process all they gonna see is encrypted version of passwords.
      The real problem with ::all() method is that it gets ALL rows in the table, even if there are millions of rows amounting to gigabytes of data. It is strongly advised to use ::paginate() method, and/or add proper “where“ filters to sql query builder.
      But all the additional code won’t make a simple tutorial example

    • @onça_pintuda999
      @onça_pintuda999 16 днів тому

      Literally after the ::all() in the docs there is an explanation about exposing sensitive data and the solution that is already implemented for it.
      Laravel handle theses things better than you imagine if you dont know Laravel

    • @ajzack983
      @ajzack983 16 днів тому

      nope, there's hidden fields specified in the model class. by default password is always hidden for example.

    • @ar1i_k
      @ar1i_k 16 днів тому +2

      lol my reply got auto removed but I still getting notifications about other replies (I hate chatGPT for making markdown notation for examples so synonymous with bots, that UA-cam auto-flags it as spam)
      As everyone else said it is hidden (=not serialised) by default. And also the password field is encrypted by default (with very powerful mutators/casts system), being decrypted only on manual access. So even if hacker gets memory dump, all they gonna see is encrypted hash.

    • @kwyaza
      @kwyaza 16 днів тому

      @ar1i_k thanks, it's been a while since I used Laravel, but still my comment was more on the caution side that simply using "all" is rarely a good idea, and it's better to be explicit in selecting fields. There could be other sensitive fields, not just the password, fields that you could forget to mark as hidden.

  • @abrahansilverio7107
    @abrahansilverio7107 16 днів тому +3

    I'm glad at least now Theo is trying things out before speaking. I dare you to find something more cool than Tailwind, Inertia, Livewire, Eloquent... etc all tools were born from PHP developers ... since PHP is a mature language with 30 years of experience, however it's not intended for frontend, but there are already solutions for most of the problems you might encounter on the web, building a backend with JS is just as annoying as with any other language if you don't know what are you doing o you're not using a framework, something that's not often mentioned is that most PHP developers also know how to work with JS very well. The era when a PHP dev didn’t know JS or frontend is a thing of the 2000s.

  • @hooyah
    @hooyah 14 днів тому

    yeah i used inertia in 2 project and its very easy to use. if you want to learn react maybe skip this stack because everything is well prepared i think, auth,db,session etc. i love this but hate this at the same time because its php not golang 🤣

  • @wego-k4811
    @wego-k4811 15 днів тому

    Love the review. But Laravel is NOT a react framework. It is part of the Symphony framework which is a php framework and laravel is just too good that it integrates other frontend frameworks like React and Vue, or Svelte as a front-end framework as an alternative to it's other main frontend frameworks like Livewire using Alpine js

  • @travisricker
    @travisricker 15 днів тому +1

    Amazing demo of Inertia 2.0

  • @lzl0_699
    @lzl0_699 16 днів тому

    What's next bringing back WordPress?

    • @moarjank
      @moarjank 15 днів тому

      Didn't have a lick of php when I used inertia with Django for a backend.

  • @JustSomeTommy
    @JustSomeTommy 16 днів тому +1

    Intertia is great, but the React part is no plus.

    • @moarjank
      @moarjank 15 днів тому +1

      It supports Vue and Svelte.

  • @ashrafjefrizin4630
    @ashrafjefrizin4630 16 днів тому +11

    Laravel for Routing + SEO + Backend
    Inertia + React for Frontend
    Voila!

  • @Unc3
    @Unc3 16 днів тому +3

    My Inertia dev ex has been so shit im not likely to ever consider it

    • @ayal4250
      @ayal4250 16 днів тому +3

      can you elaborate? worked on a clients project a couple years ago and had a really good dx. Prob because the team was amazing but open to hear your take on this

    • @Unc3
      @Unc3 16 днів тому

      Could've been a problem in the project but we tried to shove Vue into a laravel project on pages that needed a bit more interactivity. The amount of time I had to spend debugging Vue 3 Vs Vue 2, components not being cross-usable between the 2, laravel configs etc, was insane.
      It honestly felt like a hack on top of a hack. Using a tool that wasn't designed for the job, like a screwdriver to hammer a nail. Sure you can do it eventually, but would you want to?
      Having never done it before then, Laravel felt a very solid foundation, and inertia just tainted the otherwise clean solution.

    • @aydinpramasta8546
      @aydinpramasta8546 16 днів тому +2

      ​@@Unc3so the problem is migrating vue 2 components to vue 3 rather than the problem with inertia's itself yea?

    • @Unc3
      @Unc3 16 днів тому

      @@aydinpramasta8546 not migrating, but using both simultaneously. Something I never encountered when doing Vue standalone.

    • @kiiyaerick
      @kiiyaerick 16 днів тому

      How is this an inertia issue?

  • @spacegauch0
    @spacegauch0 16 днів тому

    Liorocks!

  • @jon1867
    @jon1867 16 днів тому +3

    Inertia seems basically like it's just remix written in PHP

    • @heckintosh2994
      @heckintosh2994 16 днів тому +2

      Remix came a bit later and grew quicker, but it is different in many ways. Inertia gets out of your way for the most part, whereas Remix is a whole different approach.

    • @OwenMelbz
      @OwenMelbz 16 днів тому +3

      Inertia itself is written in JS, but…. They have server side adapters for multiple languages so can use with lots of backend tech

    • @jon1867
      @jon1867 15 днів тому

      @@heckintosh2994 Thanks for the context here! I actually did not know that!

  • @Bean-Time
    @Bean-Time 16 днів тому

    Did anyone else get 3 duplicate notifications for this?

  • @apisaga
    @apisaga 14 днів тому

    using inertia on adonis

  • @lost.4676
    @lost.4676 16 днів тому +2

    Theo, forget about inertia for this moment. Focus more on your hairstyle. Man, what have you done?

  • @rajikkali
    @rajikkali 15 днів тому

    Nuxt is also a better Next.js

  • @elonmuskarabic
    @elonmuskarabic 16 днів тому

    I don't know dude the moment I saw that php code on 3:03 I just stop the video commented this comment and will live in a second sorry but I can't go back to that stupid $ sign and this -> crap no thanks

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      you can use inertia without php at all, the video isn't instantly clear about the fact that it's a meta-framework that works with many frontend and backend frameworks, not just laravel or php

  • @User948Z7Z-w7n
    @User948Z7Z-w7n 16 днів тому

    It's still in development, and defer just looks like what React use() does. Many Key features are missing for this to be 'monolith framework'. More like monolith (if you reinvent enough stuff and use enough 3rd party tools)

  • @Boi28-i2i
    @Boi28-i2i 16 днів тому +1

    🧠 used 0

  • @digitaldevigner4080
    @digitaldevigner4080 16 днів тому +2

    There is still a valid reason to create an api instead. To send the same data to a React Native, native iOS, native Android or barf-Flutter-barf mobile apps.
    Not everything happens on the web.
    Not to mention desktop, Apple TV, Meta, Apple Watch or any other device that might use the same data.
    Great solution for a web only business but that really limits the future.

    • @moarjank
      @moarjank 15 днів тому

      You can very easily reply with json instead of an inertia response based on that same exact json object. It's literally not a problem.

  • @ymi_yugy3133
    @ymi_yugy3133 16 днів тому

    This is cool tech, but I struggle to see its value.
    I feel like there is nothing on an average website that should take long enough to warrant a streaming response or if there is it's the most important element and nothing makes sense without that thing being loaded. Wouldn't time be better spend making the backend fast?

  • @ilyaskarim1952
    @ilyaskarim1952 14 днів тому

    Wow

  • @JLarky
    @JLarky 16 днів тому +7

    No

  • @TotallyRealGuy
    @TotallyRealGuy 14 днів тому

    I used to look up to you until I actually got into your industry and learned everything. Looking back, I realised all you do is repeat articles and pretend you know something about something. This is like watching your favourite video essayist and realising they're mostly talking out of their rump when they start talking about something you yourself know. Im sorry I ever looked at you as an expect.

    • @TotallyRealGuy
      @TotallyRealGuy 14 днів тому

      Oh yeah and you also harass people that disagree with you to an obsessive degree ig.

  • @anasouardini
    @anasouardini 16 днів тому

    Pff, you can't even do PWAs on those things LOL, how is it better?

  • @skt-stk
    @skt-stk 16 днів тому +1

    19 likes, fell off

  • @hamm8934
    @hamm8934 15 днів тому

    So much effort put into avoiding using something like open api. Does using something like this really save as much time as just generating an open API doc and fetching data?
    JS devs are really optimizing the goofiest stuff

  • @lifexoxo
    @lifexoxo 12 днів тому

    ua-cam.com/video/aqvFd-rwSyY/v-deo.html

  • @armanamini1450
    @armanamini1450 15 днів тому

    Lol yea you're definitely getting paid for this

  • @sebinohoo2979
    @sebinohoo2979 16 днів тому +1

    As a NextJS hater this looks really nice

    • @onça_pintuda999
      @onça_pintuda999 16 днів тому +1

      I'm a nextJs hater too. And it's nice for sure.
      2y working with NestJs (not Next) in the backend and I will never touch JS/TS for backend anymore

  • @denespapp1963
    @denespapp1963 16 днів тому +2

    come on, don't make people go back to PHP, it's still a horrible language compared to Typescript (I still have PTSD from using PHP for many years)

    • @moarjank
      @moarjank 15 днів тому

      It supports multiple JavaScript backends, apparently.

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      it's not just for php, it supports many frontend and backend frameworks, but sadly many commenters don't check out the stuff and choose to judge based on a single video.

    • @denespapp1963
      @denespapp1963 15 днів тому

      @@luigicorciulo8190 it's unfortunate that Theo doesn't emphasize this and instead makes people think it's ok to choose PHP

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      @@denespapp1963 agreed, he could've made things more clear from the beginning

  • @bugged1212
    @bugged1212 16 днів тому +4

    Pukes. Hard pass.

  • @bitcoinxofficial
    @bitcoinxofficial 16 днів тому +3

    The main problem of laravel php, buggy, slow....

    • @oussama40612
      @oussama40612 16 днів тому +9

      Isn't that the case with JavaScript as well?

    • @bitcoinxofficial
      @bitcoinxofficial 16 днів тому

      ​@@oussama40612 nodejs is also slow. However we bundle react app with golang which make our frontend restart/start in just 1 second. Simple just upload the binary to the server and run it.

    • @bitcoinxofficial
      @bitcoinxofficial 13 днів тому

      @oussama40612 nodejs, bunjs are also slow. However we found the best way to bundle the react app with golang. First we build backend API with golang, second we build reactjs ssr, third we build front-end app with golang to serve the react ssr.
      Finally just upload the two binary: backend api and front-end. Start or restart the backend or front-end app is just a second.
      With laravel, restart the api take 2 to 3 minutes. Bunjs or nodejs take around 2 or 3 minutes too.

  • @gregf3021
    @gregf3021 16 днів тому +7

    It's wild NextJS users still think their devs.

  • @whydoyouneedmyname_
    @whydoyouneedmyname_ 16 днів тому +1

    For the love of GOD, stop trying to bring back PHP people

    • @wojciechosinski5927
      @wojciechosinski5927 16 днів тому +1

      Imo it's not about PHP specifically but about DX. Convenience always wins in the end even if it contributes to software becoming worse. We've seen it for at least past few years.

    • @moarjank
      @moarjank 15 днів тому

      It supports Django instead of the backend if you'd like. I liked it.

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      it's not just for php, it supports many frontend and backend frameworks, but sadly many commenters don't check out the stuff and choose to judge based on a single video.

  • @stephanechapdelaine
    @stephanechapdelaine 15 днів тому

    Im sorry, but inertia is terrible. You don't need that. You just need laravel as backend and whatever frontend framework you want for your UI. Mixing the frontend inside the backend is bad idea.

  • @jamesdenmark1396
    @jamesdenmark1396 16 днів тому

    Its pretty ugly to me, but I think PHP guys take whatever they get, they are used to the mess code in php.

    • @moarjank
      @moarjank 15 днів тому

      I used the Django backend and loved it.

    • @luigicorciulo8190
      @luigicorciulo8190 15 днів тому

      it's not just for php, it supports many frontend and backend frameworks, but sadly many commenters don't check out the stuff and choose to judge based on a single video.