Skip to content

bachtiarpanjaitan/btx

Repository files navigation

BTX

Btx Packagist Logo

Total Downloads Latest Stable Version License Dependencies Last Commit

Requirements

  • PHP Version : 7.4+
  • PHP Modules : GD

Tested On

  • Lumen
  • Laravel

Instalation

Install using Composer

Run command composer require btx/btx, then composer dump-autoload

For, customized configuration run command php artisan vendor:publish and select index one of Btx Service Provider.

Install Manual

Download repo and extract into your {root project}/packages folder.

├── app
├── config
├── database
├── resources
└── packages
    ├── btx
    ...

Add this line autoload.psr-4 in your composer.json (You can choose one or all of them)

"autoload": {
    "psr-4": {
        ...
        "Btx\\Query\\":"packages/btx/query/src/",
        "Btx\\Common\\":"packages/btx/common/src/",
        "Btx\\Http\\":"packages/btx/http/src/",
        "Btx\\File\\":"packages/btx/file/src/"
    },
    "files": [
        ...
    ]
}

Register Service Provider into List of Service Provider.

lumen bootstrap/app.php

$app->register(Btx\Query\BtxQueryServiceProvider::class);
$app->register(Btx\Common\BtxCommonServiceProvider::class);
$app->register(Btx\File\BtxFileServiceProvider::class);
$app->register(Btx\Http\BtxHttpServiceProvider::class);

laravel config/app.php

'providers' => [
    // Other Service Providers
 
    Btx\Query\BtxQueryServiceProvider::class,
    Btx\Common\BtxCommonServiceProvider::class,
    Btx\File\BtxFileServiceProvider::class,
    Btx\Http\BtxHttpServiceProvider::class
],

then, dump autoload using command composer dump-autoload.

See detail documentations on Github Pages