Skip to content

Lavendar77/Expose

 
 

Repository files navigation

Exposé

Guide for my Laravel Applications.

Creating Traits

I had to get this in place because an upcoming project needs to use UUID for its models.
Also, Traits are good for exporting functions/logic that can be used by multiple classes. You get more standardized and readable code by using Traits.

However, Laravel (<= 6.0) does not come with a simple artisan command for creating traits. Hence, this branch.

https://github.com/cedextech/trait-generator

  1. Install package
composer require cedextech/trait-generator --dev

  1. Register service provider
Cedextech\TraitGenerator\ServiceProvider::class,
  1. Test
php artisan make:trait TraitName

About

Guide for Laravel Applications

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published