Two underrated Livewire features you need to build modern applications

Поделиться
HTML-код
  • Опубликовано: 21 ноя 2024
  • НаукаНаука

Комментарии • 27

  • @MrManafon
    @MrManafon 2 месяца назад +3

    Thank you for the video 😊 I’m a tech lead who used PHP and Elixir his whole life, up until I was forced to switch to React and Next by the market around 2018. For years it felt like it was simply impossible to sell PHP to clients, as everyone wanted either an SPA, or islands of interactivity that’d historically be very hard to implement. We’d often end up having a React app and a Symfony backend, at which point we might as well switch to Next… Videos like these, where we show how to achieve the same features, not only teach me, but make me question each day if it is time to come back. ❤

    • @gavinmurambadoro
      @gavinmurambadoro 2 месяца назад

      I have also used Next as a way to make sense of building with React. However, the different versions that Next JS has gone through in such a short time (v11 to v14 now) has given me a lot of grey hair when maintaining the apps I built on the technology. What Laravel is doing with Livewire is truly commendable. I am a strong Symfony developer but have started migrating over to Laravel due to Livewire and the developer experience they offer when building full stack and SPA-like web applications. Laravel Cloud also promises to become a major hit by providing a click-and-deploy solution to Laravel apps, similar to what Vercel is to Next.js. The time is indeed now to come back to the PHP/Laravel ecosystem, at least for me...

  • @imkyoshi03
    @imkyoshi03 Месяц назад

    This is a great topic, and I think it's time to experiment with this time to build a web app again using PHP. I'm looking forward to more content like this.

  • @GuRuGeorge03
    @GuRuGeorge03 2 месяца назад +3

    didnt know that persist existed. I heavily utilize url parameters though and they work really well. If I reuse URL parametrized properties in multiple components I also make use of traits and trait lifecycle hooks. that way you can make sure that the property is serialized and deserialized the same across all components, even if it is a quite complex object. And you have to write the logic only once. It's truly magical imo

  • @chethiyaprasanga
    @chethiyaprasanga 2 месяца назад +1

    Thanks for the videos. I'm looking forward to your application as well. If you could create a good tutorial on building a SaaS application, particularly how to link Laravel Spark with subscription-based services, it would be fantastic. Most Laravel tutorials are quite similar, but a practical, real-world, industrial-level tutorial-like those pro developers might use(like you)-would be incredibly valuable. Sharing good coding practices, microservices integration with Laravel, or how to implement microservices for a SaaS application would be great. These topics are not widely covered and would be a significant contribution to the community.

  • @marioigkiempor6579
    @marioigkiempor6579 2 месяца назад +1

    Persist is exactly what I was looking for, ty! I wonder if I can get it working with the View Transitions API 🤔

  • @JoeSmith-kn5wo
    @JoeSmith-kn5wo 2 месяца назад

    Great content.
    Just curious when you plan on releasing the course for the app you are showing?

  • @defnlife1683
    @defnlife1683 Месяц назад

    Incredible
    Side note: Damn josh what did you do to your browser for it to look so clean tho. 👀

    • @joshcirre
      @joshcirre  Месяц назад

      Thank you! And this is just Arc browser. :)

    • @defnlife1683
      @defnlife1683 Месяц назад

      @@joshcirre nice.

  • @CapitaineToinon
    @CapitaineToinon 2 месяца назад

    I gotta say, I had a few problems with wire:navigate. The caching seems to be hard-coded and can't be invalidated as far as I can tell. Also, wire:navigate on an external URL will error instead of just doing a regular page navigation, which can be really annoying if you're trying to slap wire:navigate on markdown links generated by the user.

  • @shubhamsahuSD
    @shubhamsahuSD 2 месяца назад

    I have built spa with wire navigate and handled all script issues perfectly.. now no more issues

    • @YacoubCoder
      @YacoubCoder 2 месяца назад

      @@shubhamsahuSD How did you made it ? Can you provide the code that fix the issues of rerendering the scripts

    • @shubhamsahuSD
      @shubhamsahuSD 2 месяца назад

      @@YacoubCoder can you explain the issue you are facing, i have faced different kind of issue during building spa using livewire but there is not single solution different issue have different solution..

    • @YacoubCoder
      @YacoubCoder 2 месяца назад +2

      @@shubhamsahuSD when I made a single page application with live wire and make wire navigate it doesn't reload the JavaScript code if I click to the another page or go to another big bass the wire navigate the JavaScript neutral load again if I have some code written by JavaScript

    • @shubhamsahuSD
      @shubhamsahuSD 2 месяца назад

      ​@@YacoubCoder have you mixed it wilth alpine js, Alipne js works great with Livewire, and for js assets part usi npm or if want to include through scripts tag then add data-navigate-once on script tage and write your codes inside livewire:navigated
      document.addEventListener('livewire:navigated', () => { });

  • @drugoviic
    @drugoviic 2 месяца назад +2

    Livewire is faster than inertia in my computer, i am currently still working to see if i can improve the performance score in lighthouse. An empty page with inertia running ssr returns an average score of 88 while livewire landing page returns an average score of 97 apart from switching to livewire, does anybody have any tips on how to improve performance with inertia ssr ?

    • @drugoviic
      @drugoviic 2 месяца назад

      both are using jetstream

  • @junjunghasudungan1905
    @junjunghasudungan1905 2 месяца назад

    Can be laravel make a mobile app for next step?

  • @kevinkabeya2459
    @kevinkabeya2459 2 месяца назад

    I have been looking for a reason to use persist 😅

  • @windows07
    @windows07 2 месяца назад

    Another great video! 😄

  • @AyoubWrks-nz7cy
    @AyoubWrks-nz7cy 2 месяца назад

    Livewire ❤️🔥

  • @0ni0ng0ld-g6i
    @0ni0ng0ld-g6i 2 месяца назад

    Awesome

  • @YacoubCoder
    @YacoubCoder 2 месяца назад

    The javascript dose not work after adding wire: navigate

    • @nawrasbukhari1867
      @nawrasbukhari1867 2 месяца назад +1

      Add an event listener to wire:navigated and it will work

    • @YacoubCoder
      @YacoubCoder 2 месяца назад

      @@nawrasbukhari1867 How???