PHP Classes

Laravel Service Provider Helper: Create a service and a command from a helper class

Recommend this page to a friend!
  Info   Documentation   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 36 All time: 10,981 This week: 455Up
Version License PHP version Categories
laravel-helper 1.0The PHP License5PHP 5, Libraries, Design Patterns
Description 

Author

This package demonstrates how to create a service and a command from a helper class.

It provides an example of a helper class that implements functions that can be useful for any purpose.

The package also provides how to create service and command classes that call the helper class that developers can use in an application based on the Laravel framework.

Innovation Award
PHP Programming Innovation award nominee
June 2022
Number 2
Laravel is a popular PHP framework that helps developers reduce the development time by using design patterns that promote the reuse of components in many ways.

Service and command classes are some design patterns that Laravel promotes to help developers reuse code from one project in other projects.

The package provides an example to help other developers to learn how to use a single helper class to create a Laravel service class and a command class with the minimal development effort.

Manuel Lemos
Picture of Hicri
  Performance   Level  
Name: Hicri <contact>
Classes: 26 packages by
Country: Turkey Turkey
Age: 30
All time rank: 291048 in Turkey Turkey
Week rank: 180 Up3 in Turkey Turkey Up
Innovation award
Innovation award
Nominee: 4x

Winner: 1x

Documentation

LaravelHelperClass

Latest Stable Version Latest Unstable Version License

A simple helper class implementation for Laravel.

Config

Run the Composer require command from the Terminal:

composer require qwerty/helperclass dev-main

If you're using Laravel 8.6

the final steps for you are to add the service provider of the package and alias the package. To do this open your config/app.php file.

Add a new line to the providers array:

Qwerty\HelperService\Providers\QwertyHelperServiceProvider::class

function list command the Terminal:

php artisan helper:list

  Files folder image Files (6)  
File Role Description
Files folder imagesrc (2 files, 2 directories)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files (6)  /  src  
File Role Description
Files folder imageCommands (1 file)
Files folder imageProviders (1 file)
  Plain text file QwertyHelper.php Class Class source
  Plain text file QwertyHelperCommand.php Class Class source

  Files folder image Files (6)  /  src  /  Commands  
File Role Description
  Plain text file HelperCommand.php Class Class source

  Files folder image Files (6)  /  src  /  Providers  
File Role Description
  Plain text file QwertyHelperServiceProvider.php Class Class source

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:36
This week:0
All time:10,981
This week:455Up