🔥 Laravel Tip: Dependency injection without any configuration
Apr 15, 2022
You can type-hint a class and Laravel will automatically inject an instance of that class.
Without any configuration.
This only works if the class has no dependencies, or it only depends on other concrete classes.
Without any configuration.
This only works if the class has no dependencies, or it only depends on other concrete classes.
Other tips:
🔥 Laravel Tip: Eloquent Subquery ordering
Mar 23, 2022
🔥 Laravel Tip: Disable HTML scraping in blade
Apr 8, 2021