[VOD] Laravel 13 & Livewire Blaze
Chapters6
Introduces Blaze as a high performance blade compiler and sets up the live exploration of Blaze and Laravel 13 features.
Blaze turbo-charges Laravel Blade rendering, demoed live alongside Laravel 13 basics, PHP 8.3 requirements, and Livewire Blaze benchmarks.
Summary
Nuno Maduro dives into Laravel 13 new features and the Livewire Blaze experiment with a hands-on exploration. He references the public Laravel 13 announcements, PHP 8.3 requirements, Symfony 8 components, and the new preference for attributes over traditional fillable/configs. The stream then pivots to Blaze, a high-performance Blade compiler from Caleb Porzio, and he runs live benchmarks showing dramatic speedups when rendering Blade components—up to tenfold in some scenarios. Maduro walks through how Blaze can be enabled per component or directory-wide, and demonstrates compatibility considerations when migrating existing projects. He also touches on form requests, typed attributes, and the evolving toolset around Laravel AI initiatives like Laravel Boost. Throughout, he tests on a real project, compares static vs. dynamic content rendering, and shares pragmatic notes about debugging, caching, and profiling in Blaze. The overall tone is practical testing, exploration, and crowd-sourced feedback from a vibrant PHP community watching the stream. Finally, he teases inertia 3.0 and Laravel 13’s ecosystem shifts, while inviting viewers to engage with the channel and the Lakon EU event.
Key Takeaways
- Laravel 13 drops PHP 8.2 support and raises the minimum to PHP 8.3 (with PHP 8.4 coming into maintenance later).
- Laravel 13 shifts toward Symfony 8 components and highlights the importance of keeping dependencies up to date for security and performance.
- Attributes are the new default direction for model fillable-like metadata, with explicit examples for Eloquent models, console commands, and form requests.
- Livewire Blaze is a high-performance Blade compiler that can dramatically reduce render times, with real-world demos showing large gains even with tens of thousands of components.
- Blaze can be toggled per component or applied directory-wide; memoization and compile-time folding further boost performance in favorable scenarios.
- Dynamic, data-driven Blade content benefits significantly from Blaze (first-run penalties disappear after caching).
- The session also surfaces practical notes about debugging, profiling, and the compatibility caveats when adopting Blaze in existing apps.
Who Is This For?
Laravel developers curious about Laravel 13 updates, Livewire users curious about Blaze, and teams exploring performance-minded Blade rendering optimizations. Essential viewing for developers weighing Blaze adoption in existing apps or new Laravel projects.
Notable Quotes
""Laravel 13 is dropping PHP 8.2. Okay, insanely important.""
—Nuno notes the PHP version shift required by Laravel 13.
""Blaze is a high-performance Blade compiler with a chart that shows dramatic speedups when rendering Blade components.""
—Intro to Blaze and its core claim.
""First run is a hundred milliseconds, second run is around a hundred milliseconds as well—ten times faster than blade in many cases.""
—Live benchmarking comparison between Blaze and Blade.
""Memoization and folding make Blaze three times faster than Blaze by default in dynamic content tests.""
—Blaze optimization options and their impact.
""Attributes are the new approach to fillable data in Laravel—it's cleaner and static in a lot of cases.""
—Discussion of the shift to attributes across models and commands.
Questions This Video Answers
- How does Laravel 13 impact PHP version requirements and what version should I migrate to?
- What is Livewire Blaze and how does it differ from standard Blade rendering?
- Can Blaze be enabled selectively per component or directory, and what are the trade-offs?
- What are the new attribute directives in Laravel 13 and how do they compare to fillables?
- Is Blaze compatible with existing Laravel projects using Livewire or Inertia?
Laravel 13PHP 8.3Symfony 8 componentsattributes (Laravel 13)Livewire BlazeBlade compilerinertiaLaravel AI SDKform requestsmigration considerations
Full Transcript
What's up, beautiful PHP family? How everyone is feeling today? Welcome back to another live stream. It's Wednesday, middle of the week. We are all feeling stronger today. How everyone is feeling. Dinosaurs, what's up? WWW, dude, how you doing? Whe what's up? Yo yo yo yo. Mike, how you doing? You just left for a walk. I'm on the forest right now, which is a good thing, man. You left for a walk. You are doing sports. That's fantastic. Thiago Olivivera, how you doing? Field Tix official. How you doing? How everyone is feeling today? Okay, I want to know how you guys are feeling.
Today we have an awesome live stream. Okay, we are going to dive into a bunch of stuff including including shad what's new in Laravel 13. We are going to literally explore together what's new. I don't have any privileged information about Laravel 13. So everything I'm going to say here will be or already has publicly announced. Uh actually on Lavel news I do think they have something Laval news uh Lavel 13. There is already a blog post about Laval 13. So we can use that to know a little bit what's new in Laval 13. We are going to do all of that.
Plus I want to kind of try boost uh skills which I haven't done yet. So we have a project here will be fantastic. I want to know how you guys are feeling though. Okay. Yo, what's up? I'm doing fantastic by the way. Thanks for asking. Apologize by not doing the live stream ne. Okay, but we are back today and we are back with some content. Hey CVT, how you doing? Nice to see you, man. Leo, what's up from Brazil? Mike, I'm watching listening. Well, that's a good thing. Did you use blaze? Oh my god, I literally forgot about Blaze.
Should we try Blaze chat? Should we try Blaze? Let me try. Uh, Livewire Blaze. Yeah, we can talk about Blaze 2 today if you guys want. Let's actually also do that. All right, let's do the following chat. Let's do the following. Okay, let's do the following. Very important. Let's do the following. Let's actually explore a little bit. Lavel 13 and then we try Blaze. What do you guys think about that? It's a good thing. Bam, bam, boom. Do plays plus Lavl 13. What do you guys think? Was Christine was bad to you? Uh, it kind of was if I'm honest.
So, my brother had problems uh is one of his house of his houses actually. So Christine, by the way, for those who don't know, it's basically um a tornado that happened in Portugal. But we are all good. Everyone is in good health. That's the most important thing. Chris is saying the following. Hi Nuno. I caused my first production DB deadlock. Dude, DB deadlocks, especially at scale, they actually happen more than usual. More than people think actually. It's enough actually rename a table for example to cause a deadlock or anything like that. So if you rely a bunch of on transactions and if you have expensive migration it's actually easy to do a deadlock.
Okay. Phantom what's up Patrick? Nice to see you. And uh Deepa is saying the following. There is any security updates on Laravel 13. So in fact Lavel 12 it's still maintained and it will be maintained for the next year or so. So even every time you get a new Laval version it just comes by default with security updates. Okay. You don't have to worry too much about that. Puy Paul what's up dude? Nice to see you. All right, chat. It's time to just move forward. Okay, so today we are going to do two things. Okay, we are going to dive into Laravel 13 plus explore Laravel or Livewire Blaze.
Okay, this was literally just new stuff. Okay, Blaze was introduced yesterday by Caleb Porzio I think during the Laravel live meetup I think and apparently it's a high performance plate compiler. Okay, by the way, chat, this is kind I don't know if this thing right here done by Kellerio, it's something totally new or if it's something that is already being tested on LiveWire 4 and Flux. You guys let me know. You know more than me on this kind of stuff. You guys let me know. Okay. Okay. Okay. Okay. Lucas is saying the following. Have you taken a look at the pull request that adds typed form request in Laval 13?
I have not. We can also jump into that today. Oh yeah, baby. You said that is a pull request that does that. What is that pull request though? It's like on the on the framework itself. Oh, right here. Let me see. You said typed form requests. I have not checked that. We can also check that today. Okay. All right, chat. It's time to talk about Laravel 13. Are you guys excited? If you guys are excited, just type yes on the chat. I want to know how many of you are there today. We have more than 100 people watching this live stream.
So don't forget go all the way down and do two things. Okay, very very important. You go all the way down and you click on the like button. That's the first thing you guys can do. The second thing you guys can do is subscribe my channel. Okay, super super important. It's time to move forward. But before we do that, let's say thanks to our sponsors, of course, SER API. Okay, one of the latest sponsors which you can use to grab information from search engines like Google, Amazon or anything like that. It's a simple API where you can grab all search and search search results from these engines.
It really just works. It's used by top companies like Nvidia, Shopify and more. So, you know, check them out if you can. Serapi.com, of course, Mail Trap as well, which have been this development email solution, but now it's also available for production. Check them out. They're absolutely awesome. Mail trap for the win. Redberry International. If you want to have some nice digital agency that knows how to work with Laravel, VueGS, and more. They're absolutely awesome. Check them out. How beautiful they all are. Check them out. Okay. Jet Brains International. Jet Brains, of course, the company behind the best editor in the world, PHP Storm.
Check them out. Titan. Of course, Titan, the company that builds and rescue web apps and development teams. They're also responsible for the book Laravel up and running by Matt Staer which recently released a podcast Lavel AI if I'm not mistaken. Check them out. Of course, Code Rabbit if you want to have some nice pull requests being reviewed in GitHub through AI that are awesome. And Devon if you want to offload some tasks uh using AI using Slack or Linear. They're absolutely fantastic. Check them out. Wsponsors for the win. Chad, I have a new video on my channel about native PHP.
Yes, native PHP. If you want to do some mobile development using PHP, you can literally using native PHP. Okay, really just works native PHP. You cannot like my stream twice. Oh, okay. Well, thank you though. Firto, what's up? How you doing? Filipa, nice to see you. 373323, nice to see you as well. How you guys doing? W sponsors for the win. Okay, W sponsors for the win. What else we have in terms of news? Do we have anything new? No, we don't. Uh, I think that's it. Yeah, let's move forward. All right, Shad, it's time to talk about Laval 13.
Okay, Laravel 13 for the win. And by the way, in case you guys don't know, something you guys can do to explore a little bit what's new in the new Laravel version is just go to this Lavel/Lavelare and you can literally compare two branches. So if you want to know everything that have been merged on the core or it will be merged on the core for a lot of 13, you can literally do this comparison. Okay, if you scroll all the way down, you have literally access to all of the changes done on the skeleton but plus done on the core.
Okay, you just have access to all this information. Okay, let's start small. I actually have a list of changes that are publicly announced. Okay. Uh, let me just open this here with Sublime Text. Okay. Bam. Bam. Boom. The very first change is that Laravel 13 is dropping PHP 8.2. Now, PHP8.2 is kind of dead already if I'm honest. Nobody should be using PHP.2. I don't think it's even maintained anymore. Well, as you guys can see, PHP 8.2 only his only have security fixes at the moment. Okay. And by the end of the year, not even security fixes will have.
Okay. By the way, chat, I want to hear from you. Which PHP version are you guys using at the minute? Okay, just type on the chat, which PHP version are you guys using at the minute? But P Lavel 13 is dropping PHP 8.2. Okay, insanely important. Okay, CVT is using PHP 5.6. Oh no, dude, that's old. Okay, that's old. Very, very old. No good, huh? No good. No good. No good. No good. A lot of people relying on PHP.4. 4 which is a good thing. Okay, PHP.4 is almost the latest version. Just be mindful that by the end of the year PHP 8.4 will be equally not maintained anymore.
Only security fixes will be uh merged into PHP.4. So I would advise you all to migrate to PHP 8.5 which is the latest version. A lot of people from X by the way X people just move to my YouTube channel man. youtube.com/nunaduro. That's where people are. My YouTube channel or the Twitch channel. It's just a much better. Okay. All right. Most of people, if not everyone, except CVMAL apparently are using PHP8, which is a good thing. Okay. Which is a good thing. Um, but yeah, if you can migrate to PHP 8.5, Laravel 13 will drop PHP 8.2.
Okay. You need to be on PHP 8.3 if you can. All right. What else? I just noticed something if I'm not mistaken. Yeah, Taylor Otwell actually committed a change to the readme which talks about agentic development. Okay, and it says the following. Okay, it says the following. Play close attention. Laravel is predictable structure and conventions make it ideal for AI coding like cloud code, cursor or github copilot. Install Laravel boost to supercharge your AI workflow. And honestly, this is more important than ever. You kind of just need to be ready for agentic development. That's the only thing that matters in the future.
Okay? People won't care if your code is solid, if your code is super whatever. The only thing it matters if is that if AI can produce good code with the framework and at laval we are investing a bunch of that and you can actually see things like laval boost being super important. Okay, laval boost for the bin. W boost everyone. Okay, w boost boost is important. Share. Don't forget 150 people watching on YouTube right now. Go all the way down and click like on this video if you can. Okay. If you can. New welcome page.
What do you mean? New We have a new welcome page. Mr. Pual is like on fire. Does that mean if I type PHP artisan serve, will I be able to see a new welcome page? That will be sexy if I can have that. Let me see. Let's load. Let's see. Let's see. Let's see. Oh, not bad. If I'm honest, it's not that new. It's kind of close or similar to the page we had before. Okay, let me just hide my image right here. Bam, bam, boom. Looks like this. Okay, it looks a little bit better if I'm honest.
It's a little bit more compact and kind of handy. I like it. And we can also click on this view change log apparently. Oh, which proxies to the change log.md file. Not bad. Not bad if I'm honest. Okay. Not bad. Okay, Laravel 13 with so many options options available for you. We suggest to start with the following. Read the documentation or watch the videos on Lacas. Okay, Laracas is still the best way to become a developer. I know a lot of you guys are new to the scene, okay? New to development in general. Lacastas.com is the best way to learn anything regarding web development.
Okay? And they are not sponsoring anymore the channel and I still recommend them. That's how much I trust them. Okay? Larakas wakas. Okay. What do you think about blaze chat? We are going to explore blaze on this live stream as well. Okay. We were supposed to explore Laravel boost skills, but we are going to see Laravel or Livewire Blaze, which apparently makes Laravel blade like a thousand times faster. I kind of want to explore that a little bit. Okay. All right. Let's go all the way down. The feature flag. Pay close attention, chat. Everyone looking at me.
The feature flag coming to Laravel 13 are attributes. Okay, are attributes meaning the following. This kind of code will continue to work. Okay, if you are migrating from Lavel 12 to Lavel 13, this kind of code will continue to work. However, however is expected to see on Laravel 13 filables as the new approach uh um attributes as a new approach to kind of fill this property value. So, I want to hear your opinion. If you think it's a good change, type yes. If you don't think it's a good change, type no. But also explain why do you think it's not a good change.
Okay? And personally, I like it. I think it's way more compact, way better in general. Like, just look at the size of this compared with literally this. Okay. I think it's just much better. Okay. Pull for attributes. I don't know how to do a pool on this thing, man. CVT Mal, can you take care of that? Kind of feels weird about attributes. Shad, I'm going to be honest. Like attributes in general, they may look a little bit spectically different from you are you are used to, but you will love them. Once you start using attributes, you will love them.
Okay. All right, Chad. You will love attributes. Yeah, attributes are fantastic. Okay. And you are going I was just making a list, Chad. Just look at this. I literally asked cloud code, can you give me a list of all the new attributes coming to Laravel? And the list he have made is the following. Let me just copy paste to show you. Okay, let me just copy paste to show you. I'm going to open here a new file. Let's type here new scratch file real quick. Uh plain text. This is the list of new attributes coming into a lot of L13.
Okay, we obviously have a bunch for eloquent models. Okay, so feelable, guarded, Eden, visible, appends, connection, blah blah blah blah blah blah. So all of this stuff can be used and should be used under app models user.php as you can see here. Okay, beautifully like that. All right, Shad. By the way, Shad, don't forget go all the way down and click like on this video. Insanely important. Okay, so all of this stuff can be used like that. But we also have attributes for many other things like Q jobs for example. Okay, so if you want to customize the number of tries, you can do it through attributes.
Uh let me actually just try something. If I type PHP artisan make job uh process podcast. Uh for example, uh let's just type enter here. This should create a new job. Here we go. Do we have them already here? We don't. But to customize the tries, I think it would be just like this. Okay. I kind of like it if I'm honest. Okay. I think this is very sexy. Very, very, very sexy. Do you guys find this sexy? Let me know what you think. I think this is sexy. There is some, you know, static information immediately visible all the way top of the class name.
I think this is very sexy. Yeah, very very very sexy. Me is saying the following. Do you you when you use past php and sqlite in memory and then use production light mysql well in general mar you should use the same database driver in your test suite as the one you are using in production okay in general however for my projects like pinkory for example I you know I don't mind of using a different database for the testing okay let's see let's read the chat so many people talking today you guys are absolutely awesome okay You guys are absolutely awesome.
Let's take a moment to read the chat. Roberto99 is saying the following. Well, you can you can write properties in one line without the comments and still have the same compact style. That's true. But there is one problem attributes are solving that nobody is literally talking about, but did you solve? And I'm going to show you which problem it is. Okay. So, when I was working uh on the open source team at Laravel, uh I was actually assigned with a task which is uh type the entire framework. Okay. And one of the things we couldn't just simply do is just type all the attributes immediately because if I wanted to do this like for example type this array thing like this I couldn't do it because that would be a breaking change and I didn't want to do a breaking change for every single property everywhere.
Okay. So one of the things that attributes equally solve is that we no longer need to type this property because the new API it's simple attributes. Okay. But also like it technically looks better but in general if you think a little bit about this this information also should be static information accessible statically basically. So if you want to know like on the user table how many things are eaten or feelable you don't need to technically instantiate a new user model. You can just statically access that information through attributes. So it just makes sense honestly. Okay.
It just makes sense. Okay. Okay, so Pia Paul is saying the following attributes are good. I agree with you. Exodon is saying the following. Ad came in and hijacked the screen. I apologize. I apologize, but you love attributes in general, which is good. Mike is saying the following. Symphfony style, they are used everywhere. I think like the PHP ecosystem in general is converging to attributes and that's a good thing. Okay. And again, I was just showing you guys this is coming for eloquent models, okay? It's coming for Q jobs. It's coming for console commands as well, man.
So, if you type something like PHP artisan make command, let's just say import users for example. Let's actually do that. I expect to see attributes already. Here we go. Here we go. Okay. Console commands equally using already attributes. I think this is way more clean. Way more clean. Great explanation. Thank you so much, man. Appreciate. Appreciate. Bam. Bam. Boom. Chat. excited to be back. Uh, Phantom is saying the following. I think attributes are going to be huge. Uh, imagine 30 fillable columns. That's a good point. That's a good point. Actually, I think Taylor raised that on Slack yesterday.
Uh, what happens aesthetically if we have a fillable of, by the way, you shouldn't be using fillable to begin with. But let's assume you use fillable. What happens if you use a fillable of more than like three things, for example? Well, aesthetically would look like this, which suddenly I don't like it anymore. I probably would. I don't know, man. I probably will still use this or just don't use fillable to begin with. It's problem solved. Okay, you don't need fillables anyway. Honestly, I would if the framework was Noo-Noo, fillables would be gone from the framework.
I still don't understand to this day why fillables exist. I think they're a waste of time. Like, you literally validated things through form requests. Like, why would you add this extra layer of protection at the model level? in Wyatt model level and not anywhere else. I don't know. Shad, I want to hear your opinion. Do you guys use fillable? If you use feelable, chat, everyone type yes. If you don't, just type no. Okay, Ron, though, by the way, in terms of thinking that attributes look ugly, I think like that's a question of just starting using them and suddenly you'll find them beautiful.
Okay, is a is a question of just starting using them and you are going to love them. Okay, by the way, we have 200 people on the live stream today. go all the way down chat and type uh and just like this video if you can. Just take a second. It really, you know, makes means a lot to me. Just click on the like button and you also click on the subscribe button if you want to see more PHP content on my channel. We have a bunch of [ __ ] a bunch of good [ __ ] if I'm honest.
Native PHP AISDK full review and more. Okay, even Symfony 8 you can see here. So cool stuff. Cool stuff. Fillable is a must. That's interesting. So I want to know why do you think fillable is a must? I want to know from you. Okay, I kind of always get confused about that but I want to know from you why do you think fillables are a must. Okay, because for me it just feels like a layer of protection which kind of overrides a layer of protection that you already have on form requests. So if form requests are validating the input and you are being defensive already over there like why would you add another random validation somewhere?
It doesn't make any sense to me, you know. Following the Laravel conventions. I don't know. I don't know. All right, Shad. So, what else? We have attributes. So, we just saw attributes on commands. As you can see here, this looks fantastic. What else? We have attributes on form requests. Okay. On form requests, uh we can literally, for example, say something like stop. This is sexy by the way. Stop on first failure. PHP artisan make request uh let's say create user request for example. Okay so if we do this we can equally now just go all the way top and say something like stop on first failure.
This is useful. Okay. And I honestly think that stopping on the first failure should just be the default anyways as well. Okay. Bam bam boom chat. Uh one question from Sesa is saying the following. Does Laravel 13 improves uh the performance uh compared with Lavel 12? Uh I am unaware of any performance improvement. However, however, it's worth to mention that Lavel 13 will boost the underlying Symfony components being used. Okay, that's worth to mention. Okay, so if we go to the core and now I am at Lavel/framework and I'm going to scroll all the way down to see all of the changes in terms of files changed.
Uh one of the things we see is that on the composer.json, JSON which should be right here. Here we go. We see that now we rely on Symfony 8 components. Okay. Which may or may not introduce security uh performance improvements. Now one thing that will for sure introduce uh performance improvement is the required PHP version. So of course if you need to jump uh from PHP.2 which is no longer supported to PHP 8.3 or PHP 8.4 4 or PHP8.5 you will just get a massive performance improvement automatically shed automatically. Okay. Automatically GMC is saying the following uh fieldable will probably help uh protect users that don't follow conventions and don't validate form data as much as they should.
Shet this is insanely important. Okay. Form requests are probably the thing you should pay more attention than ever in your code. So when you see a pull request, when you see a pull request coming from your team, there are two things you should pay very very close attention. Okay, very close attention. The first one is migrations. Okay, migrations are very hard to change. If you make a mistake on migrations, you are doomed for the future. Okay, it's very hard to change a migration. Like renaming a a table for example or renaming a column for example or changing a column type is very expensive.
it may lead to deadlocks for example. Very important always validate migrations. The second thing which is very important is form requests because it's literally the layer of protection between the outside world and your code. Okay. So form requests are the most important thing ever when um validating codes on um when validating um a pull request. And I have that by the way in case you don't know yet. I'm working on my own starter kit again. I know another starter kit which is called it malfit kit u it's a work in progress will be the most complete starter kit I have ever shipped in my entire life I think it's malfit kit yes it's malf kit and one thing you guys are going to see here is that I enforce form requests at every single entry point of my application including things like a list uh listing a table for example so everything goes through form request to make sure that input is always safe and valid.
Okay. Okay. Bada boom, bada boom, bada boom, bada boom. Um, request all is faster. I'm going to pretend I didn't read that. Okay, that's no good. Barack, no good. No good. No good. Always take a backup. That's important. Test your uh have backups and test your backups. Zoro 161, by the way, I was with you yesterday on Laravel Cloud Develop um anniversary. Thanks for the support. It's saying the following. Zoro w from request. I love my controller to be simple. Exactly. That's the reason why I love form requests and I'm a big fan of them.
So, for example, if I go here, I can go into this uh session controller for example and there is literally form requests all over the place as you guys can see. Okay, form requests are super cool and I love them in general. Okay, user export controller as well. Um, this doesn't have any form requests but let me see. User profile for example, of course, have an update user form request as well. Form requests are beautiful chat. I love them. I love them. Okay, let's continue chat. Let we need to focus. Okay, we still have to see Lavel livewire blaze today, but let's focus a little bit in understanding what is still new in Laravel 13.
Let's go to the scratch document. And apparently like we also have a few attributes for the HTTP resources. We have attributes for factories as well. That's interesting. So if I type PHP artisan make factory team factory for example let's just do that here we go and I'm going to go to database factories team factory I expect this little thing to be using interesting this is not because we don't need yeah I think like even the user factory does not need that I actually did this I did this feature where factories automatically or automatically detect uh the responsive model so I don't think we even need that yeah that's no no no necessary.
Okay. Yep. Yep. Yep. This is attributes. I think this is a 10 out of 10. I love this feature. Okay. Yeah, we are going to try um liveware blaze uh not on this project but on a lot of L12 project and I'm kind of curious to see the speed. So, we are going to potentially try that all together. Okay. All together. Okay. Techie is saying the following form requests are overkill for validating one three one or three fields. Uh that's kind of true. However, let me tell you the following. If you use form requests all the time consistently, AI will equally use them as well.
So, it's a little bit also about that. Okay, you need to think a little bit about the newcomer to your team which will basically do features like you guys do and then will try to copy you because he wants to basically have the code as you do and it just makes sense to just use form requests all the time. Okay. Bam. Bam. Bam. Boom. Why use controllers and form requests when you have live wire? Well, I don't use well, I haven't I have a few projects where I don't use live wire. I kind of use live wire and pinky, but I don't use live wire.
For example, on this recent project I'm developing which I'm using inertia and react. Okay, by the way, chat, we have close to 200 people watching the live stream. Don't forget going all the way down. Okay, very important. Go all the way down and click like on this video. Okay, super important. Okay. Also, form requests may be reused uh in your API plus the web uh part of it which is interesting. Okay. What else we have on Blavl 13 chat? Bam bam bam boom. Dino started saying the following. I use lot of data from spacious form request.
A lot of people have been pitching to me lot of data as being a good thing. So potentially that's a good thing. Okay. Ronato is saying the following. By using actions pattern controllers become almost redundant. They don't actually because again actions don't rely on the HTTP layer. They can be used in isolation. They become simple. I give you that. Okay, I give you that. So if you go here for example, typically controllers will almost always look like this. Okay, you have a form request, you have the current user, you have the action and you just proxy the validated information just like that to the action.
They become literally like this. I do give you that uh but that's it. Okay, you still need them to kind of reanswer this the HTTP layer. Hello from Scotland. How you doing, dude? Nice to see you, man. Nice to see you. All right, sh let's move forward. What else we have on Laravel 13? Laravel 13 for the win. Uh boom, bada boom, bada boom. And I think that's mostly it. So I literally have a list of changes which some of them were literally compact and uh done by cloud code. But I think like in terms of changes that is you know that's it attributes the latest PHP 8.3 version uh 8.3 being required and I think they said in terms of changes on Laravel 13.
Now you guys need to be mindful about thing about one little thing which is mainly and super important. Okay Laravel major versions are now about making sure Laravel is using the latest in the greatest of the PHP ecosystem. As you guys can see, Laravel release 13 is introduced uh or dropping uh PHP 8.2 is relying on Symfony uh using Symfony components, the Symfony 8 components, which is the latest version. It's also like um fixing various little things that need to be fixed on the major version. As you guys can see here, there's a bunch of little things which are not really end user uh but they're important to do it on a major version.
And it's mainly about maintability because and this is equally important. Laravel SDK was released outside of this package. Okay. A lot of SDK by the way in case you haven't seen is a new package by Taylor which introduced uh a easy way of developing AI related applications in your app and this was released outside of this huge chunk of Laval 13. Okay. Okay. New middleware in LA 13. That's not a new middleware. That's cloth code hallucinating. Okay. Jill Dwart is saying the following. Hi Noo. What is your user strategy for a multi-tenant application? I just don't do multi-tenant applications.
That's it. How to use a policy? I don't think policies are good. So don't use them. No deers or files changes. Uh we do have a few changes. So if I go here for example, um no there is no directory changes. So the skeleton is still slick and simple. So if you click on Laravel for example here and if we open the 13 branch right here, there is no changes on the directory structure. Just looks the same as usual. Okay. And I think looks good honestly. Okay, that looks good. I like I was part of the development of slimming the skeleton a little bit and I think now it's just perfect on its perfect state.
Okay, bada boom bada boom bada boom. What else I want to talk about 13? Oh, I want to talk about something really important. Okay. So besides mintability um changes, we also have lot of LAI SDK which was released like literally two weeks ago. But we also have inertia 3.0. Okay. Now very important for those who are inertia users. By the way, do you guys love inertia? If yes, type W inertia. Okay. W Inertia. Inertia 3 is coming out. Apparently Joe Tenonbau will demo some of it at Latakonu. Now I don't know what it's coming to inertia 3.0.
I haven't been informed yet about what's coming up to inertia 3.0, but it's a new major version. Okay, it's a new major version. Okay, Gert is saying the following. Inertia needs to go. Why you think that? Inertia is absolutely awesome, man. Flee, thank you so much for subscribing my Twitch channel. I appreciate your support. Thank you. Thank you. Thank you. Thank you. Thank you. You are so awesome, man. Thank you. boom. Laravel cloud is kind of multi-tenant application supporting multiple organizations. That's true. Inertia is awesome, man. I feel you. I feel the same. I love inertia, man.
And it makes Typescript development much easier. I agree with you. Okay, so Inertia third 3.0, it's also kind of part a little bit of Lavl 13. Okay, so this is what we have for Laravel 13. Just as a recap, we have a bunch of attributes being introduced on the apps and you can actually use them like this. Okay, a bunch of attributes. They look fantastic. Okay, we have mintability improvements including using uh Symfony 8 components plus dropping PHP 8.2 too. And we have two major re-releases being introduced including lot of valley SDK and inertia 3.0.
Okay. Is livewire versus inertia or view? I use both. I think both livewire are awesome. Have you gone through Caleb? Is blaze video chat? Let's actually check blaze video. Okay, let's actually check blaze. I want to check blaze chat. What do you guys think? WL blaze or should we do anything else? Blaze for the win. What do you guys think? Blaze, Blaze, Blaze, Blaze. Okay, this is the Blaze thing, I think. There is no changes on Laravel uh kernel system on Laravel 13. Okay. What's up, Jonas? How you doing? W Blaze. Okay. Should we do Blaze chat?
Let's do Blaze. You guys ready to check plays? Let's do it. Let's do it. All right. What is Blaze chat? Let's just take a close look into this. Blaze is a high-performant Blade compiler ensures applications that push Blade to its limits stay fast even if your component count grows. And this is always a concern when you guys um work with blade in general is that it's very easy to to fall into this trap where everything every single thing is a component like a button is a component then a table cell is a component as well and then suddenly you have other thing which is a a component as well and suddenly you have like [ __ ] 4,000 components being rendered on the page.
Okay. And this is always a pain or how it have been a pain with blade. And apparently what blade solves is exactly this problem. Okay. And there is actually some comparisons here which are kind of mind-blowing apparently. Okay. Mind-blowing. Um so here for example we have an example where rendering with blade takes 7 seconds. Okay. And with blaze it's just literally less than a second. Okay. And I want to try this. Let's actually try this [ __ ] Okay. That is like a profiler and everything like that. So let's just do it. By the way, some of you were telling me that there is a video where Caleb just demoed this a little bit.
Can you guys send me that video already? I want to see that. Send me the video, Chad. Send me the video. Meanwhile, what I will do is create a new Laravel 12 project real quick. Okay, so let's just do that. Laravel new Laravel. Okay. And uh yeah, if I have a plated, I want to use this. Not now. Just a regular Laravel project. Yep. Yep. Yep. With past with boost. Send me the send me the video about Blaze chat. Ronato, thank you so much for the subscription on Twitch. You are absolutely awesome. Thank you for supporting my work, man.
I appreciate you are awesome. Oh, you guys cannot post links. I forgot about that situation. Where do I see that video though? It's like on Twitter. Let's open Twitter chat. Let's open Twitter real quick. Uh do I have Twitter even? Uh yeah, I do. Okay, let's go here and let's just type Caleb Porzio. Post the ID. What do you mean? What do you mean? Uh where is the video? You guys telling me a video? What video are you guys even talking about? There is no video. What are you guys talking about? Which video are you guys talking about?
YouTube video ash. Oh, so if I just search Livewire Blaze on YouTube will just give me something. Well, there is the YouTube meetup. Is that what you guys talking about? Is this the video you guys talking about? Cloud. Is this the video you guys talking Oh, Beacon just sent me the link. Okay, okay, okay, okay, okay. We have the video chat file if it doesn't exist and PH. Okay, let's take a brief look into this. If it's like too big, we just try it ourselves. Okay, P is just running those compiled files. Let's look at them.
So there is one compiled file for every blade component or every blade file. Every blade file has a matching PHP. Okay, so what he has here is literally it will create 25,000 components. Okay, will create 20 f 25,000 components and include that component 25,000 times. Okay, the compiled version, right? So, this is the button one. It's just button and then it has this little note here called path that says this is resources, views, components, button.blade.php. And then this one is our benchmark blade file. So, it looks nearly identical except you're not going to see blade in it anymore.
You're going to see an echo statement. And this is pretty interesting. If you take a look, you'll see that add include is doing what I showed you before. Make array diff render. It's doing all of those things. That's what's happening under the hood. Now, take a look. If I render X button like this and hit save, this is what gets compiled a lot. And you look at this and you go, "Oh, blade components must be slow because they turn into like 20 lines of code." It's not. I've learned that things like if statements and is said and assignments, they're basically free.
The slow things is resolving a view by name, array merging, instance of like should render, resolve, all this extra stuff, you know. So this is how blade ph Brandon, thank you so much for the subscription on Prime, man. I really appreciate you are awesome. Compilation works just to triple like drive that point home. You write some blade here and it turns into actual PHP in a file somewhere else that now if we we have hey a million times. You can modify this compiled file and not the source file just to prove to you that the compiled file is the thing that gets run.
The source file is just a reference and they compare the file modified time so that if this file gets modified and it's sooner than the other one then it'll By the way, I haven't seen this before. Okay, this is the first time I'm seeing this. Compile that file. Okay, makes sense. And that's why the first request is always slower than subsequent requests um when you're using Blade. Okay, back to business. Let's keep going. Uh how do we make it fast? Okay, you learned about some slowness. You learned about why it's slow. Now we need to make it fast.
Of course, this is what Blaze is for. I give you Blaze, a high performance Blade compiler with a chart. Look at that. This is without Blaze. You'd be a a poor 1.0 yet. So you're required in your application. Okay. So here is requiring the package for the first time. Great. Now you have blaze and if you want to use it, you have to add it to a component that you want to use it. So let me split this down and open up buttonblade.php. Okay. And now I want to blazify this. So I write at blaze.
So any component that you Okay. To opt in to use blaze you just use arublaze. Want to make really fast with blaze you use at blaze. You can also alternatively I think right here we have this you can in your service provider you can optimize entire directories. So, if you don't want to do this on a per component basis, you can just say blazeify all of my components in my app. Okay, so you add blaze and now, whoa, did you see it? Well, we didn't actually. Let's go back to this. Let's go back to a normal empty button blade component with Blaze.
Woo! Got it down to 18 milliseconds. So, that was for the compile time, so that's always longer. And then subsequent times, it's 14 milliseconds. So, that's pretty cool. What Blaze does is it basically takes away 90% of Blad's overhead. I'm so sorry you have to hear me say the word blade and blaze constantly. You should, you know, I'm more sorry for me because I have to keep them straight all the time. Let's actually try this. So basically an empty button went from 85 milliseconds to 40 millconds. I want to try this [ __ ] chat. This this watching on the video thing.
It's it's just, you know, it's annoying. So how do I make a component on blade? I haven't used bla blade for [ __ ] 10 years, man. So I I don't even know. Okay. Can I do something like this? Let's just do this. Uh PHP file button.blade.php. Can I do this? I think I can do this. Okay. So what what should be the content of the button? Yeah, I can just have this button. Okay, let's actually do an empty button. I think we can do that. All right, click me. Okay, and now I can go to the welcome page.
Uh, do I want to remove all of this? I think yes. Uh, so on the body, we can just include uh the button thing. Yep, yep, yep. That should work. So I should see a click me button here. PHP artisan make component. Yeah, I can still do this though, right? I can just have a normal blade view here. Okay, let's include this component. And now if I open this, I should actually see um click me. Oop, let me just start the server real quick. PHP artisan serve. Ooh, PHP artisan serve. Here we go. So it's running and I see click me.
Okay, it's kind of a little bit uh let's just actually remove all of the CSS. We don't need CSS on this. We actually don't need any of this [ __ ] Yep. Yep. Click me. Okay, so we have the button being rendered. And obviously we can render as well like 20,000 buttons. Okay, let's actually do that. Let's type here. Where is the video? So I can do a PHP for each loop which a range of 25 20,000 25,000 buttons. Okay. So, let's actually do that. So, PHP for each and that's to a range of 1 to 25,000 as I.
Okay. And for every single one of them, I'm going to just render the button and just close the for each loop. Okay. So, this should actually render like 20 [ __ ] buttons. Here we go. We have all of that. Now, we need to basically benchmark this [ __ ] So what we are going to do is basically let's actually benchmark this by doing something like do we have a benchmark class on PHP? I think we do. Yep. Benchmark. How do I use this? Uh benchmark dd I provide a closure. I have done this by the way but I barely remember anything.
Try to use the for each to see if there is a difference. I will do it. Okay. I will do it in the future. I will do it. Uh simplify this. Let's do benchmark dd and then let's actually just convert let's actually render this view to string. Okay. So the result will be I'm going to convert this to a string. So it can be actually rendered in parsert. Okay. And finally yeah I think that's it. So if we go to the homepage we should see already like a benchmark and we do. Okay. So apparently 20,000 25,000 components it's taking yeah more or less what he said basically 48 milliseconds I think.
So this is without blaze. Okay. Are you guys ready to try blaze chat? Type wlaze if you guys are ready. Okay. Wa blaze if you guys are ready. I kind of I'm a little bit curious to see like um if the W if the AOA for each changes anything though. And for each does he changes anything? It makes it slower actually. That's interesting. Wow. Okay. W Blaze chat. Here we go. 200 people watching the live stream. Chat. Super important. We are testing live wire blaze from Caleb Porzio. If you guys are enjoying today's live stream, go all the way down, click like on this video and subscribe my channel.
Okay. Super important for supporting my work. Okay. So, composer require livewire blaze. Okay, live wire blaze. I'm going to go here. Going all the way top. Make it like this. Composer require live wire blaze. Cannot find directory. I'm going to fix that in a second. I'm going to fix that in a second. Here we go. Composer require live wire blaze. So, that's done. Something I want to do though is that I want to just enable this by default. I want I don't want to do like uh only this component thing. Okay, I want to do just enable this by default.
Let's see if we have an option to do that. Um, do we have documentation? Maybe it's on a GitHub read me. Yes, it is installation getting started. Uh, option one had the blaze directive. That's something we can do. Option two is just do it. No. Yes. Okay, we can just do it apparently. I think in the betweens. Uh, we're about to find out. Does it matter? Okay, we can just type place optimize apparently on the boot method. Let's actually try that. So, I'm going to go into providers, app service provider, go into the boot, and then I'm going to just type blaze optimize.
Okay. And the resource path will be views. The entire views pad will be optimized. Okay. And that's it. I think that's it. Yeah, I think that's it. There is limitations, but we don't care about limitations yet. Let's type PHP artisan view clear. Apparently, that was a requirement. Okay. Bam. Bam. Boom. Okay. So, we were with 50 milliseconds if I'm not mistaken. Yeah, 55 milliseconds. And we are about to hit the refresh to see how it goes. Okay. To see how it goes. By the way, we have a bunch of new Twitch followers. I appreciate you guys are awesome.
I really appreciate PH Bundon. Thank you so much for the subscription on Prime. Ronato as well. You are awesome. Okay. All right. Let's give this a refresh. Basically, we just have optimized the entire view path and let's we are about to just click refresh. Wait, what? Is this [ __ ] [ __ ] real right now? No way. Holy [ __ ] No way. This cannot be true. I'm going to comment this view cleared again. This is [ __ ] insane. Wow. So 100 milliseconds with blaze is less than a millisecond. This cannot be possible. Is this [ __ ] true? Wait. Oh my god.
What the [ __ ] is this, man? Are you guys seeing this, chat? Wplays, everyone. Let's just type Wplay Blaze, chat. Oh my god. We need to just type Wplays. Just What the [ __ ] This This is like ridiculous [ __ ] All right, let's do the following. I have just tried live wire blaze and my example went from 90 that was 90 millconds. I don't want to lie to people. Okay, let's just let's just do it again. Let's just do it again. Yeah, my example went from Even the first run just takes forever. Okay, literally 100 milliseconds. Okay, what the actual This is like ridiculous though.
My example went from 100 milliseconds to less than one millisecond. What the [ __ ] Okay, just what the [ __ ] 25,000. Uh the example was rendering 25,000 blade components. Like what the [ __ ] This is just ridiculous, chat. That's I got confused about that one though. Like why didn't we saw 20 55 milliseconds before? Like I was so confused though. I was a little bit confused. I'm going to be honest on that one. So view clear. I'm going to just type PHP artisan clear. So we don't have anything like literally on cache at the minute. Okay. We go back to the example.
We refresh. Okay. Now we are making a mistake. Yeah, we need to uh comment this. PHP artisan clear. I just refresh this. What the [ __ ] Okay, this is using blaze still. Oh, PHP artisan clear will not basically clear the view stuff. Okay, now it is. I've refresh. Here we go. The very first time though, it takes almost half of a second. So, it takes half of a second on the first run. But then once it's cached takes close to 100 milliseconds. Yeah, it takes 100 milliseconds. Like no, no, no [ __ ] We see it takes a 100 milliseconds afterwards.
This is second run. Okay. And then with blaze. So if I go here clear cache clear view clear. Now I run this takes up one millisecond on the first run. So 1 millisecond first run. Subsequent runs. This is just [ __ ] this is ridiculous though. Like what the [ __ ] Insane. Whoa, whoa, whoa, whoa, whoa, wait, wait, wait. Chat, chat, chat. So, Gino is saying the following. Who is going to run 25,000 components on a single page? Just thinking, dude, that happens more than you think. Like on things like filament, for example, where like every single button is a component.
It just happens a bunch. I'm going to give you an example. Okay, imagine that you have a table list. A table list. Okay, this table list displays 100 elements. Every single element have 10 buttons. Do you understand? Do you understand? Every single uh row have 10 buttons. Every single row has [ __ ] five table cells. Okay, are you seeing this? Like this kind of stuff, it just escalates a bunch. Suddenly you have 25K. I I can tell you that. Okay. No, no. Hundreds of components. It's not too far-fetched. It's not having even thousands. I'm going to be honest with you.
Okay. People are saying, "Can you try Blaze on Pinkery?" That would be cool though. Oh, can we do it? Wait a second. Can we do it? That would be cool though, right? On Pinkery. When using nesting. Exactly. When you use nested components, it just gets wild. Like honestly, this this is this is really cool stuff, okay? Really really really cool stuff. Oh my god, this is ridiculous shaded. I'm going to post this um I'm going to post this on Twitter as well. This is just ridiculous. Filament 5 solves partially this problem but in the same way as Caleb did.
I think Caleb went a little bit a little bit more deep than what people may think. I was wondering if I can have Pinkery real quick running the test suite locally and try with Blaze. Should we do it? Give me a moment. Let me let me see. I don't even know if the Pinkery test suite runs locally at the minute. Give me a moment. I'm going to just close this project and open Pinkery real quick. Let me let me see if we can try Pinkery. I don't even have Pinkery installed on this laptop, I think.
U Nuno Maduro. Do we have Pinkery here? Oh, we do. Wait a second. Maybe I can try it. Uh let me just full screen this view terminal. I'm going to just type here Gpool because obviously there's a bunch of [ __ ] here. Uh composer install npm run. Oh, it's not even on PHP 8.5. Okay, one second. Composer install. Okay, now it's working. npm run build. Okay, I'm going to just try quickly the Pinkery uh test suite and if it's working potentially Ooh, it's running. Okay, we may have a shot on this one. Yes. All right, [ __ ] it.
Let's just do it. All right, Shad. I'm going to share my screen. This is pinkory.com. Okay, shad pinkory.com. The website that powers the social media. Pinkory. Okay, so I just literally clone the project, run the test suite, and we have the test suite running. 800 tests running in in 10 seconds. So I'm going to install Blaze on this [ __ ] Okay. And if it's working, probably I will just push it. Composer require uh Livewire Blaze. Okay. So I'm going to just require LiveWire Blaze real quick. El Poo Reaver, thank you so much for subscribing on Prime for 4 months.
I appreciate your support. Means a lot to me. Thank you so much. So, we just installed Livewire Blaze onpinking.com. This is a production website, chat. A production website. Okay, I did say partially. You don't like filament, dude. Filament is the best admin planet admin panel in the planet. Okay, filament chat, I'm going to say this again. Filament is the best admin panel, the best backend thing on the entire planet. Okay, on the planet. I'm talking about across languages, across frameworks. W Filament everyone. Okay, wilament. So I just typed this and now what I will do is that I'm going to go into the app service provider on pinkory.com.
Okay, so I'm going to go into providers app service provider. Let's go into the boot method. Here we go. And I'm going to type uh blaze. Uh what do we have here? I forgot literally the syntax. Uh is this the one? No, no, no, it's not. Le blaze. Here we go. So I just have to type this blaze optimize. Okay, let's just do it. So blaze optimize. Should I just optimize? I'm a little bit curious like why Blaze by default is optimizing only the components folder. Can I not optimize the entire view pads? I must feel like I can just do it.
What do you guys think? W Filament. Exactly. Chat, exactly. Nothing let Oh, here we go. Mitchell is saying the following. Nothing lets you create an admin panel faster than filament. It's just the best in the planet. Okay. Exly is saying the following. Interesting. Has been a year or two since I have tested it. Probably have matured a lot since. Yeah. You know the feel the the feeling that it's bloated. You will not get out of that feeling. It's indeed with a bunch of [ __ ] Okay. But it you just get stuff it just you just get stuff happening just faster than anything else.
Okay. That's it. All right. Shad. I am requiring blaze all over the place. Okay, requiring the blaze all over the place on entire view path. And now I'm going to run the test suite. This will be interesting if this works. No, it's not working. It's already failing, shed. Okay, I'm going to type with bail. Yep, it's not working, Shed. It's not working on my test suite at the minute. Okay. Uh that's why we have tests, by the way. Okay. Okay, it's important. So, at the minute, uh, a lot of my testuite is literally failing on pinkering if I optimize, uh, the entire view path.
Maybe there is a reason why, uh, Caleb portso, uh, we recommend you starting with specific directories as your app may rely on features Blaze did not support. Oh. Oh, there is a bunch of [ __ ] that is not supported, including view shared is not supported. Oh, I see. Aware view composers creators life cycle events will not fire. The component variable is not available. Class-based components are not supported which we may have a few on this one. Okay, that's why blaze making tests fail. Yeah, makes sense because the tests are integration tests meaning that they render blade.
They actually render Blade to see the output on the terminal. We have test browser testing uh on pinky.com and everything. So Blaze will be part of the test in some sort. Okay. By the way, chat 250 people watching the live stream. Okay. So go all the way down, click like on this video and subscribe my channel will mean the world to me. Shad subscribing my channel. Okay. We have videos about pretty much everything. Native PHP, Laravel AI SDK, Open Code, AI, Laravel, Symfony, everything. Okay, just subscribe my channel would it would mean the world and the planet to me.
Okay, and the planet. Here we go. Here we go. This is a channel for everyone. All right, sub it. Thank you. Thank you. I appreciate. By the way, chef, next week, in fact, this Friday already I will fly into Lakonu. Does any of you will be there? Laku, it's coming. Okay, I will be the host. So, but a at 9:15 you will see me on stage um already saying something like hello. Welcome to Lakon EU. You guys are fantastic. I am as well. It will be awesome. W Lakon EU happening soon. Okay, I will be the MC.
What else we have to know about Blaze? So, apparently Blaze is [ __ ] fast, which is probably will be my default on fresh new LiveWire apps. However, to existing projects which might be relying on some features that are not supported by Blaze, it won't work yet. Okay, by the way, I noticed you always mention Shad. Who is he does anyone knows who is shed? Optimization strategies by default uses Blade uses function compiler works virtually all components and provides significant improvements. I'm wondering if I can just use Blaze on the components folder. Do we have a components folder to begin with?
Resources, views, components. We do. Let's give this a try, chat, real quick. So, views components. Okay, let's give this a try. Maybe now will work. Uh, no. Will still not work. [ __ ] Let me try PHP artisan view clear though. Ah, still not work. It's not okay. Undefined ver variable version. Yeah, because the version is is shared on view share. I think I think it's somehow using Vue composers. I think we are all shaded. Here we go. Here we go. Lacon India will videos will be published on YouTube or similar. Hopefully they will. Okay. Hopefully they will.
Shad, I want to try Blaze a little bit with another example. Let's go back into the previous Laravel app we were working on and see how Blaze behaves over there. Okay. With other things. All right, just open it real quick. Bam, bam, boom. Here we go. Uh, I want to try a few other things. Someone was saying to try different things. What do you guys want to try here? What other things could be potentially interesting to try it on? Well, actually something we could try it on is what happens if we have dynamic information on the button.
That's a good point. That's actually a very good point. Okay, let's type here text equals to button I. Okay. So that's some dynamic information. Click me. Uh and this will be text. Just that. Bam. Just like that. Okay. Text text. So this should work without blaze. So I'm going to just type PHP artisan view clear. I'm going to go into the app service provider. I'm going to remove blaze. And if I go into my web page, I should basically be able to render this. If I activate the server real quick, let's actually do that. So, PHP artisan serve.
Yep. It's even slower. Jesus [ __ ] Christ. Oh my god. This will be a good example chat. Are you guys ready? So, with dynamic information with dynamic information, blade is even slower. Okay. So, we had, let me just double check this. So, I'm going to go here and just type PHP artisan view clear. So the very first run it's taking 800 milliseconds which is close to a second. Okay. So let's just notice. So this is like static and here we have some dynamic behavior. Okay. Dynamic behavior shed. The very first running taking close to a second.
The second run taking Let me just move the way out of this ghostly thing. Here we go. The second run taking 400 milliseconds. The second run. Okay, now with Blaze. Let's see. Are you guys ready? W Blaze if you guys are ready. Sh, have you guys tried Docker? What's your opinion for it in Lavl? I'm not a fan of Docker. I've used Docker in the recent project. It was problems every single day. I'm not a fan of Docker. Okay, I I understand that many of you are fans of Docker, but once you are using the stability of Laravel Herd, I love it.
Okay, Laravel Herd for me is just a goat. Okay, Laravel Herd for me is just a goat. Docker is a no-go. I have tried Docker countless times. Every single time I get disappointed cuz it's just not stable. Just [ __ ] not working all the time. It's just annoying. Bada boom, bada boom, bada boom. That's just my opinion, chat. It's just my opinion. All right. Dynamic information with Blaze. Okay. Dynamic information with Blaze. Let's go here into the app service provider and let's actually activate blaze once again. So blaze optimize in the resource path views. Let's type PHP artisan view clear.
First run. Okay, first run. You guys ready? First run 3 milliseconds. First run is this is like so ridiculous honestly. Second run. This is really like [ __ ] unbelievable honestly th this is unbelievable. Okay, unbelievable [ __ ] Unbelievable [ __ ] we are watching right here. Okay, this is insane. Insane. This is very impressive. Very very impressive [ __ ] we are watching here right right now. Can you check if it's actually rendered correctly? Yes, let's actually do that. That's a good point. That's a good point. Very good point. Very good point. Okay, let's actually make sure this is actually working as expected.
Okay, so I'm going to return the blade view just like that. Okay, let's just return the blade view to see if it's working. That's a good point. And it's Oh, wait, wait, wait, wait, wait, wait, wait, wait. Okay. Something is not working here without blaze. Let's just try. Okay. It's not that. It's something else. Oh, here we go. Okay. We have literally a button. Okay. With dynamic information on it. Now, I'm going to activate Blaze. I'm going to clear the view and I'm going to hit the refresh button. It's indeed not working, Chad. Okay. It's indeed not working.
This is a buggy example. Exactly. Why though? It doesn't make any sense. Do you guys think like Wait, wait, what? Wait, what? So, I'm just including a button with some text on it. And that text will be this one. Okay. maybe try with less buttons. I don't think that's that's even the reason. Well, let's actually do that. No, that's not the issue. Let's see the compiled version of it, though. Let's go here into the storage. No, that's Yeah, storage framework views. And we have the compiled version here. Yeah, it talks about LiveWire Blaze and everything, but it's indeed not working.
That's weird. Oh, do you mean that we actually need Well, that's a good point. That's a good point. Someone is saying that we actually should move the button the buttons to the components folder. cuz view welcome need render blade not blaze. Oh I I I understand you. So but what are you saying is that we should basically move the button thing to the components folder and now we can just do views components just like that. Okay. It might be that though. It might be that. Okay, let's just type PHP artisan view clear. Okay, let's go back to the 25,000 components.
Okay, we have them back. Let's comment this. So, I just refresh the page. I see like literally all of the buttons. Button not found. Yeah. Yeah, I need to update that. Let's go back to the welcome page. This will be uh welcome. No, not welcome. Components button. Okay. And I can just render. Yep. 35 million components. Cool. And I'm going to go back app service provider. Activate blade. Clear the views. Run it again. It doesn't work. Like what the [ __ ] Yeah, there is nothing on it. Okay, Chad. I'm super confused right now. What I'm doing wrong though?
Uh, let's go back to the video. Oh, it's using X button. Do I need to do this? Can I can I not use the include thing? Let's actually use the X button situation. It might be that just that. Yep. Now I can use the X button just like this. Let's go back with uh non-dynamic information to begin with. So click me. There is no dynamic information here. yep. I see it. This is with Blaze, by the way. Okay, so that's working. So with dynamic [ __ ] Oops. Here we go. So it would it it was just basically the the fact that I was equally compiling the welcome page.
Okay, now it's working. What the [ __ ] Now it's not working. Okay, so the problem was chat that we were basically telling Blaze that the welcome page were equally a blaze component when it cannot be. Okay. So here we are going to do is view components to kind of have a full a full an actual test on this one. Okay. So if now if I just view clear this will work again. Yes. All right. We're ready. Okay. We ready. So let's start with the non let's just redo all of this. Okay. Because all of this [ __ ] may be wrong now.
Okay. I don't know anymore. So let's do let's do again this the entire story. Okay. So view clear. Just type PBR isn't clear. So everything is clear. We have on the welcome page we have a static button being rendered. Okay, a static button being rendered which is called click me. Okay, everything is cleared without blaze and we need to add the benchmark back. Okay, so we'll just do this. So, without blaze, this is taking uh unable to locate. Oh, okay. We need to fix this. Uh, one second. This needs to be moved away to components.
Yep. Bartik is saying the following blazes for components, not for layouts. Exactly. Okay. All right. Sh. We ready to just do the test again? Okay, we're ready to do the test again. So, I'm going to refresh this. And we have 900 milliseconds on the first run. 5,000 milliseconds on the second run. Okay. So, view clear. Let's go again. First run 900 milliseconds. Okay. This is static information. Uh let's go back to the app service provider. So, static information. This is blaze. Uh, blade first run. Second run 5,000 milliseconds. 500 milliseconds. Sorry. And now we uncomment this.
We view clear. We clear again everything. Okay. We back on the game. We refresh this. Okay. The results are not even close, chat. The results are not even close to what we were talking about. It's still five times faster, but not crazy [ __ ] Okay, not crazy [ __ ] So, first run is taking 100 milliseconds. That's still 10 times faster, which is still crazy. Second run still 100 milliseconds. Interesting. I want to just clear again everything to make sure of this. Yep. In second run. Yep. In second run. A little bit faster. Like 10 milliseconds faster. Still faster.
[ __ ] Still impressive. Still impressive. Okay. Still impre impressive. So this is still static. Okay. So blade and this is blaze. All right. So, TLDDR for static components, we have Blade taking close to a second on the first run and Blaze is is literally 10 times faster. Okay, on the second run, Blade takes 500 milliseconds while Blaze takes 100 milliseconds. Okay, 10 times faster sh is still very impressive. Okay, it's not as impressive as that less than millisecond thing, but it's still very impressive. Still cool [ __ ] here. Okay, you need to uplate your post. Oh [ __ ] the Twitter post.
Oh my god, I forgot about that. Oh no. Oh my god. No good. Oh [ __ ] We need to just [ __ ] delete this [ __ ] No good. No good. All right, we good. I just deleted the thing. We good. We good. We good, chat. Okay, we good. So this is static information. Okay, now let's comment this already. Let's go back to the welcome page. Let's actually now use dynamic information. So click me and then this will be just text just like that. This will be text button XYZ. Okay, good stuff. I'm going to go to the app service provider and I'm going to comment this going all the way top.
PHP artisan view clear. PHP artisan clear. So we don't have anything on cache. We go back to the browser. Okay, we refresh this sh dynamic information. We have more than a second on the first run. Okay, a little bit a little bit more than before. Okay, so blade has what the [ __ ] was this? Like listen to me or what? What the [ __ ] Okay, so first run more than a second. Second run close to 500 millconds again. So it's not that different actually from the static information. Never happened. Exactly. Sh. Don't forget go all the way down and click like on this video.
Also subscribe the channel. Super important. Okay. Next. This is blade. So we good. Okay. Now we are going to activate blaze. So activate blaze on the view components thing. I'm going to clear cache and clear the view clear. So everything is cleared and I'm going to go back to Safari. Refresh this button. First run 149 milliseconds. Okay. So that's that's a 10x the way. That's that's still a 10x First run 150 milliseconds. Second run very close to the very first run. Interesting. I would expect it to be faster though. Pick and flow, thank you so much for how many gifted subs, dude?
Five gifted subs. I appreciate your support since day one. Pick and flow. You are absolutely awesome. Someone is saying, wait, wait, wait, wait. Someone is saying to use the MIMO true. What does the MIMO true even means? Or the fold one? We are going to check that in a second. Big and full appreciate five gifted tier one subs, man. You are absolutely awesome. You have gifted close to 100 subs on this channel. Okay, thank you so much for your support, dude. You are awesome. Um, yeah, that's 10x. That's a TLDDR. Okay, chat. TLDDR 10x improvement on 25,000 components.
Okay, on 25,000 components. Woo, Puyal is saying something interesting. Should you benchmark the welcome page minus? That's true. That's true though. Yep. Yep. Yep. Like without the buttons. Oh, that's a good point. You mean actually just come here? Yeah, I can probably do that, too. That's a good point. I learned so much from you. Thank you, Pick and Flow. You're awesome, man. You're also a good friend of mine. Okay. I love to match you last year at Lacon US. That was awesome. Um, boom, bada boom. I want to check the MIMO true. What the [ __ ] is the MIMO true situation?
So, LiveWire Blaze, we are just here. Optimization strategies. By default, Blazes uses a function compiler which works virtually all components and provides significant performance improvements. Bada boom, bada boom, bada boom, bada boom. You might consider advanced strategies below. They require additional thought and care. Okay, the function compiler is true by default. I can do MIMO true for repeated components and the full true for maximum performance. What is this [ __ ] though? Okay, let's actually use this. Um, wait, but I cannot do the I cannot use this. Wait, wait, wait, wait, wait. Can I use this on the app service provider though?
Blaze optimize. What the [ __ ] This is returning config. Okay, what is config? Oh, I just have to call this should memoize and shoot fold, which is a little bit annoying. I think I'm going to use the play directive thing at the minute. Yeah, let's use that. I'm going to go here into the button thing and I'm going to go all the way top blaze and I can just use memo apparently, right? What's up? What's up? What's up? How you doing? [ __ ] Blaze looks awesome though. Like, can we just agree on that? Can we just type all W Blaze?
Because I love when people question existing standards. This is when you create stuff that is actually impactful for everyone is when you question the existing stuff. A lot of people think like when you are creating a project that you can't you are not allowed to question the existing stuff. If I wouldn't be allowed to question the existing stuff I wouldn't be able to develop things like lot of pint or past php all of those projects they question existing stuff. They're making question like why do we need a configuration on on p ph p ph p ph p ph p ph p ph p ph p ph p ph p ph pHbpcs fixer or why do we need test files to be classes you know we are just questioning existing stuff place is no different we are literally questioning the existing blade compiler basically which is [ __ ] here forever okay so let's just type here mimo true apparent let's just copy this from the docs okay let's copy this from the docs so blaze can I yeah here we Oh, I just specify this as arguments.
Okay. Can do I need to do it like that or I can just do fold true. I don't know what these options are doing but we are going to find in the second. Okay. So, let's actually render this on the page to make sure it's working as expected. So, what I will do here is just for now I'm going to return the view welcome just like that. Okay. And I have activated blaze so I don't need to do it at app service provider level. Here we go. Let's actually go here and just type PHP artisan view clear.
An expected identifier DR. What do you mean? Oh, yep. Yep. Yep. We need to remove this. Uh PHP artisan view clear. PHP artisan clear. Let's make sure we render this on the page. Let's go back into this beautiful thing. Yep. It works. So, with a MIMO in fold, it's still working. Okay. Okay. It's still working with a MIMO in the fold. Okay. I still don't know what this [ __ ] thing does, but we are about to find out. Okay. So, next step, uh, what is the next step? Uh, I'm going to go to I'm going to go to what I'm going to go what am I doing?
Okay, I'm going to remove this view thing and I'm going to benchmark this stuff. Okay, so again, PHP isn't clear. PBR view clear. And I'm going to go all the way top and render this [ __ ] again. So, we are about to see the benchmark. Okay, with a benchmark with a MIMO stuff and with a fault parameters. Okay, this is optimization strategies which are not enabled by default which apparently also make things faster. Okay, before we do that, let's just say hi to everyone. E Joel, what's up? Nice to see you. Join us, what's up, dude.
It's the first time you're talking today. Pilsky, nice to see you as well. Bruno, Michelle, Merak, hi everyone. Welcome to the live stream. In case you don't know me, my name is Nuno Maduro, PHP Lavel developer. I love what I'm doing. And what we are doing is uh using Laravel blaze for the win. Blaze is not enabled. So apparently there is two ways you can enable blaze. Okay. Number one. Number one you can enable it on the our app service provider which is right here or you can enable it at uh component levels which is exactly what we are doing here.
Okay. Meaning that in terms of benchmarking what I do expect to see on this example we are trying right now is something close to this. Okay. Did I talk about Laval 13 already? I did. I'm sorry, man. You can watch the VOD afterwards. Okay, chat. Chat, don't forget go all the way down and put like on this video if you are enjoying today's content. Also, subscribe the channel if you can. All right, chat. Let's just refresh this. Okay, chat, let's just stop right now. Much faster than before. Okay, much faster than before, chat. insanely important dynamic information with blaze with memorization and folding.
Okay, the first run is even faster. Okay, chat. All right, the first run is even faster. I want to see the second run though. Close to it. Okay, close to it. So apparently with blaze with memorization in folding it's three times faster with bl than blaze by default. Okay. So this is what we have dynamic information with blade. First run takes a second. Second run takes 600 milliseconds with blaze without any option. without any option is taking 150 milliseconds in both runs with momentization in folding it's even faster. Okay. And again the example we are talking about the example we are talking about is literally this a for each example where we are running 25 25,000 buttons.
Okay. I was wondering like what is the limitations of runtime memorization and compile time folding. Wondering if they're talking about that. Yep. Runtime memorization, which is the option mimo true. This strategy is ideal for icons, avatars, or any other elements that frequently appear with the same props. When the meization component appears in multiple pages, um the render only happens once. Interesting. Very interesting. Compile time folding which is another option we have used is uh Blaz's most aggressive optimization. The component ceases to exist at runtime. No function call, no variable resolution, no overread whatsoever, just HTML.
that's very interesting. Oh, thank you so much for the two bucks VR one super on live stream. That's my very first one. So, I appreciate your support. Restore the deleted tweet. We can do a new tweet. We can do a new tweet, chat. I think I think we can do a new tweet. Let's actually do it. Okay. Bam, bam, bam, boom. I think like we can just use um dynamic components. Okay, let's just do this. Dynamic components example. Okay, this is what we have. Let's actually screenshot this. Uh, leave me alone. Just like that. And let's actually screenshot this.
Just like that. Okay, let's tweet the situation. We need to tweet this situation. Okay, let's go back. Import this image real quick. Uh, this is the one. All right. Just tested Livewire Blaze and what the [ __ ] Okay. And what the [ __ ] Seems that by default is 10 times faster than blade. And with memoization plus folding, it goes further than that. Okay, I like this. this. What do you guys think? Good tweet. Bam. It's done. Here's the link, chat. Boom. Boom. Boom. Boom. Boom. Boom. Boom. Boom. It's not dynamic with Mimo. Wait, what? What do you mean it's not dynamic with MIMO?
So, we have a button. Let me just confirm that we have a button with Mimo. True. We clear the cache. We clear pretty much everything. Let's render the button to see if it's dynamic. You guys are [ __ ] kidding with me at the moment. I just tweeted it again. Uh, it is dynamic. I literally seeing dynamic buttons right here. 24, 25, 26. It's It's working. This on this example is working. I'm honestly happy with this, man. I think like I'm happy with this. This is Blaze looks fantastic. Looks [ __ ] fantastic. What else we have to see here?
Yeah, we have considerations. I don't really care about them. What else? What else? What else? Slots. Yeah, there is obviously a few things we guys need to pay attention on. Debug mode. What is this? Oh, we need to check Check the storage framework view file that's compi that's compiled with Blaze. So I expect to go here into storage framework views and see like blades [ __ ] Ooh, we don't. Oh, because of the folding. I think folding just basically does not even create the compile thing. But if I do this then we are going to see a compiled version.
There we go with Blaze. Okay. Much simpler version than the ones in Blade. Okay. Blade is much more [ __ ] as you can see. Maybe the fold override the MIMO setting. Yeah, it might be that too. [ __ ] It's time to see the debug stuff. Okay, let's go back into the readme folder. And apparently we have some debug situation. Debug mode. Blaze includes a powerful debug mode to help you measure rendering performance. Compare blades against standard blade and find performance bottlenecks. How to enable debug mode? Go to the boot method and just call blaze debug. Let's actually use this.
So app service provider, let's enable debug mode. Just like that. And then set the environment variable to blaze debug true. Okay. Bam. Blaze debug. True. And what else? PHP artisan clear. Okay. Done. And what else? I just go there. What the Oh, wait, wait, wait, wait. We have something here. Chat. Open profiler. What the [ __ ] is this? Wait a second. We need to fix the view uh actual size. Here we go. Wow, this looks handy though. Yep, we don't have any memo or folding activated. Let me just confirm if I go to the button. Yep, we have just blaze normal.
Normal blaze. And this is basically a way of checking the performance entry. What happens if I refresh this? Nothing happens. Okay, let's go back into the profiler. Refresh this again. We see the blaze thing all the way down. You guys cannot see it, but I'm going to show you. Here we go. The blaze thing all the way down. You see it? Let's open it. By the way, chat, don't forget, subscribe my channel, okay? If you want to see this number going up, just subscribe my channel. I'm literally trying to understand this profiling situation. Eliss, what's up, dude?
How you doing? Nice to see you, man. I'm literally trying to understand how the [ __ ] this even works. yeah. I think what what we are going to what we are seeing right now is that rending the welcome page and its components it's literally most of its time it's taking actually running the 25,000 components. Okay. Oh actually no. So the welcome page just the welcome page for example it's taking 62 milliseconds as you guys I don't know if you guys can see because it's super small. Let me try to zoom in. I can I zoom in?
Yes I can. Okay. Maybe this way you guys are going to see it. One So the welcome page, just the welcome page is taking 62 milliseconds on that parameter called itself time. And the components is taking the rest of the time. Yep. As you guys can see. Okay. So 60 milliseconds is just a welcome page. But then the 25,000 components is 123 milliseconds. Someone is saying this profiler can be used for all views even without blades. That's a good point. Is that real? So if I go to go to if I disable blaze here. If we do view clear.
All right. Let's just clear everything. Let's go back to Yep, it's rendering. I'm going to open the profiler. Yep. It works without blaze apparently when you are out of blade. Out of blade basically, you see it on the blue thing, which is obviously much slower. As you guys can see, it's almost second here on this very first run. Good [ __ ] man. This is good [ __ ] Okay, good [ __ ] W debug mode on um Blaze. Okay, this is honestly this is a proof that projects like this are super interesting in 2026. Still super interesting. Okay, everyone talks about AI.
This is what I care about. Okay, this kind of stuff. What's up, Maxi Tacos? Welcome to the live stream, man. How you doing? The $24.99 buttons will use the cash version. Yeah, that's expected. Okay. Good stuff, man. Good stuff, chat. I think that was it for this today's live stream, man. That was awesome. Oh, there's also Blaze Enable, Blaze debug, Blaze throw. Okay, what else? And MIT, of course, super open source. Let's see a little bit of the code, though. Is Caleb is the mighty Caleb Porsio using past PHP? Oh boy, we see past here.
Compiler compiler test is using past PHP W passed in Caleb boards you okay here we go here we go testing and using expectation API beautifully just like that wasthat WW past get ready for super long method names what do you mean how many dependencies this project has it just relies on Laravel that's it and the parser of Nikiti Okay, I don't know if you guys know, but this PHP parser thing done by Nikita Papov is literally used by PHP stand, past PHP, pretty much everything that requires parsing PHP at the minute. Wasted for the win.
It's being tested against Flux. Good [ __ ] man. What happens with the source code? Is Caleb Porzio still using types or not anymore? Oh, he's now using types. Interesting. Because I know that at some point Killer was not happy with types. Now he's using types again. Okay. Well, for example, Livewire doesn't have any types on the source code. Now, it does have. Okay. Good [ __ ] Good [ __ ] chat. Good [ __ ] All right, chat. That was an awesome live stream. I had a bunch of fun. I hope you guys had fun, too. We had We just had a bunch of people watching today's live stream, which is absolutely awesome.
chat. If you enjoyed today's live stream, don't forget, go all the way down, click like on this video. I'm going to probably do a video about Blaze, which I think like deserves its own video even outside of this stream. And I'm going to probably probably publish that video tomorrow or after…
Transcript truncated. Watch the full video for the complete content.
More from nunomaduro
Get daily recaps from
nunomaduro
AI-powered summaries delivered to your inbox. Save hours every week while staying fully informed.









