Reviewing Folder Structure 0:00Okay, so I think that brings us to the conclusion of this series. Naturally, there's so much more to learn, but that's for a different series. So why don't we finish up with a very quick review of the folder structure. Now, like I said in maybe the first or second video, yeah, if you take a look at all these directories, it can get kind of overwhelming. But now, maybe it's not quite so bad once you know what each one does. For example, your Gulp file, you learned how to use Elixir to compile down your SAS, or you can even use LESS or Browserify, or if you need to concatenate or compile, lots of cool stuff there. So that's this file.or if you need to concatenate or compile, lots of cool stuff there. So that's this file. Package.json is a node-specific dependency list, very much like your Composer.json file is for PHP. Next, some things we didn't review, like testing, but we have a full series on that. Anyways, here's your phpunit.xml file, which basically means when you run phpunit, it'll read this file and apply all of those settings. Next, we have a few other files specific to Git, nothing overly interesting there. You have your environment file. And remember, you would create this locally, but also a different version for production. Environment and Dependencies 1:05You have your environment file. And remember, you would create this locally, but also a different version for production. And that way, for example, you can set your local database configuration here. But for production, yeah, those settings will be different. So on your server, you would use different values. Or even a basic example, appenv, we're setting our environment to local, but on your server, you'd create a file and set that to production. Anyways, what else? Well, we have the vendor directory, and this is where any of your Composer dependencies are installed.Well, we have the vendor directory, and this is where any of your Composer dependencies are installed. Generally, unless you are referring to a particular file, you don't really need to worry about it too much. Here's your test directory, when you're ready to get into that. You have your storage directory. Again, you don't need to worry about that too much at this point in your learning. Resources is where you will store any of your JavaScript files, or in this case, your SAS files. And if you'd like to dig in more to JavaScript,or in this case, your SAS files. And if you'd like to dig in more to JavaScript, I recommend going through the Vue series, V-U-E. Just search for it at Laracastas. Anyways, next we have our public directory. Now, if we go back to resources, actually, your JavaScript and your SAS, those will all compile down into the public directory. And ultimately, those are the files that you will reference within your Vues. Okay, continuing on, our database directory. Yeah, we can create model factories. Database and Migrations 2:25Okay, continuing on, our database directory. Yeah, we can create model factories. Not sure if we covered it in this series. Maybe not. But if that's the case, once again, we've covered just about every possible thing related to Laravel. So just give it a search, and you can refer to that more. Generally, it's a quick way to define the blueprint for a particular model and table. And then that way, you can quickly whip up any number of rows. So if I want 10 users, I could say factory for a user, and I want 10 of them.And then that way, you can quickly whip up any number of rows. So if I want 10 users, I could say factory for a user, and I want 10 of them. Done. That will instantly create 10 fresh test users within my database. Next are migrations. We learned about how useful this is and how it's sort of like version control for our database. Very cool stuff. Next, your configuration. Yeah, you'll constantly reach for these files. Config and Queue Drivers 3:13Next, your configuration. Yeah, you'll constantly reach for these files. So for example, when you set up caching for your site, yeah, maybe initially you can get away with the file driver. But once you start getting a lot of users, you'll probably want to switch that out for something like Memcached or Redis. And the same is true for a number of these. For example, when you start learning about queues, yeah, here we're using sync, which basically means do it all in one process. But for production, you might want to use Beanstalk.yeah, here we're using sync, which basically means do it all in one process. But for production, you might want to use Beanstalk. That's what Laracast uses. Or you know what? For basic stuff, the database driver would be great. No problem there. And then once again, of course, you could use Redis if you want. Now, don't forget, though, these settings define them from your environment file. So this second argument, if I undo this, that is the default. So what we are saying is read from the environment fileSo this second argument, if I undo this, that is the default. So what we are saying is read from the environment file and look for the queue driver setting. And if you don't find anything, default to sync. Otherwise, use what it says. So what you might do is for production, once again, you would set queue driver to, let's say, database. And now instantly behind the scenes, everything will be swapped out. Very cool stuff. OK, so continuing on, bootstrap. Customizing App Structure 4:25Very cool stuff. OK, so continuing on, bootstrap. Yeah, you don't actually have to worry about this directory too much. Mostly it's just a Laravel-specific code for bootstrapping the application. Notice we register some things with the container, very much like we learned one or two lessons ago. OK, next we come into your actual application. Now, before we review these directories, a very, very common question is, well, what about when I have classes that I don't really know where they go? And I think people often forget that you can modify this directory structure however you want.well, what about when I have classes that I don't really know where they go? And I think people often forget that you can modify this directory structure however you want. So if you, for example, have a class related to, I don't know, campaign monitor, well, then you could maybe put that within an emails directory and call it campaign monitor. Does that make sense? So yeah, anytime you have a different section or functionality and you don't know where to put it, just create a folder. No problem there whatsoever. So maybe you create a forum and you decide, App Directories Overview 5:21No problem there whatsoever. So maybe you create a forum and you decide, well, you don't want to group the forum controllers and the models with the rest of your application. OK, well, then at the very least, you could create an app forum directory and then maybe there you would have thread.php. OK, no problem there whatsoever. Anyways, let's go ahead and delete both of those. Now, one thing we haven't covered in this series is the console. So you learned about how to use Artisan, where you say php artisan,Now, one thing we haven't covered in this series is the console. So you learned about how to use Artisan, where you say php artisan, and we referred to maybe half of these commands. We didn't cover queues and some of the other stuff, but you'll get into that when you're ready. But anyways, you can also extend Artisan by creating your own custom commands, which is very cool stuff. As always, we've covered that at layer casts. Next, events, exact same thing. We didn't get to it in this series, but we've already covered on the site.Next, events, exact same thing. We didn't get to it in this series, but we've already covered on the site. So I highly recommend learning how to use these once you start to feel the pain of code all existing in one place and you don't really want to keep it there, but you don't know what the alternative is. Well, it might just be that firing an event is what you want to do there. Next, if you want to create any custom exceptions for your application, you could put it here. You also have the HTTP layer where you learned about middleware and controllers.you could put it here. You also have the HTTP layer where you learned about middleware and controllers. Good stuff. We have jobs. Now, again, we didn't get to that in this series, but we've covered it at layer casts. A job is a way you can fire, well, either a self-handling command, which is like an instruction to your application, maybe something like purchase lesson could be the name of a class and also stored in the jobs folder.maybe something like purchase lesson could be the name of a class and also stored in the jobs folder. And you can even tell it to run asynchronously or through a queue. And that way the user doesn't have to wait for that full operation to complete. Instead, we handle it in a different process to speed up performance. Okay, next listeners that will be connected to the events that you fire. So you will learn about both of those at the same time. Okay, policies moving on. So this is related to Laravel's gate functionality. If you search layer casts for ACL,So this is related to Laravel's gate functionality. If you search layer casts for ACL, you'll see a few different videos that you can refer to. Generally though, this is how you handle authorization with Laravel. And you'll even find that there's some cool blade directives. For example, I could say within a blade file, well, if the user who is currently signed in can update the post, well, in that case, let's add a edit post link and stuff like that. I think you'll like it. And then finally, yeah, the providers, Next Learning Steps 7:51I think you'll like it. And then finally, yeah, the providers, you learned about that in the previous video, I believe. So hopefully you're starting to see that initially it's all very overwhelming. But one step at a time, you begin to figure out how each of these pieces of functionality connect with one another. So let's switch back to Laracast and go to skills, Laravel. At this point, you are now finished with Laravel from scratch. So yeah, I recommend continuing on with this skill set. So you can learn what was new in Laravel 5.1.So yeah, I recommend continuing on with this skill set. So you can learn what was new in Laravel 5.1. So for example, lots of cool stuff that we didn't go over in this series, but it would be good for you. For example, when I talked about the gate functionality and the gate facade, yeah, lessons 13 through 16, we'll go over that. Next, yeah, continue on. Figure out some of the cool new stuff in Laravel 5.2, which is the version we used in this series. And then you can move on to intermediate Laravel and building a projectwhich is the version we used in this series. And then you can move on to intermediate Laravel and building a project and learning some cool Eloquent techniques. So lots and lots of fun stuff here to keep you busy a very long time. So I'm Jeffrey Way with laracast.com, and I'll see you in the next series.