Skip to content

Laravel Utils is a package that configure simple things, which we usually forget about in our projects.

License

Notifications You must be signed in to change notification settings

datalogix/laravel-utils

Folders and files

NameName
Last commit message
Last commit date
Apr 26, 2024
Dec 13, 2024
Apr 26, 2024
Dec 13, 2024
Dec 13, 2024
Oct 17, 2020
Jul 18, 2023
Apr 26, 2024
Oct 17, 2020
Oct 17, 2020
Jul 18, 2023
Apr 26, 2024
Nov 28, 2020

Repository files navigation

Laravel Utils

Latest Stable Version Total Downloads tests StyleCI codecov License

Laravel Utils is a package that configure simple things, which we usually forget about in our projects.

Features

Installation

You can install the package via composer:

composer require datalogix/laravel-utils

The package will automatically register itself.

Translations

To publish Portuguese translations (pt_BR), use the command below:

php artisan vendor:publish --provider="Datalogix\Utils\UtilsServiceProvider" --tag="lang"

Configuration

The defaults are set in config/utils.php. Copy this file to your own config directory to modify the values. You can publish the config using this command:

php artisan vendor:publish --provider="Datalogix\Utils\UtilsServiceProvider" --tag="config"

This is the contents of the published file:

/*
|--------------------------------------------------------------------------
| Laravel Utils
|--------------------------------------------------------------------------
*/

return [
    'model' => [
        'unguard' => env('UTILS_MODEL_UNGUARD', false),
    ],

    'locale' => [
        'category' => env('UTILS_LOCALE_CATEGORY', LC_ALL),
    ],

    'schema' => [
        'defaultStringLength' => env('UTILS_SCHEMA_STRING_LENGTH', 150),
    ],

    'https' => [
        'forceScheme' => env('UTILS_HTTPS_FORCE_SCHEME', app()->environment('production')),
        'middleware' => env('UTILS_HTTPS_MIDDLEWARE', app()->environment('production')),
    ],

    'paginator' => [
        'defaultView' => env('UTILS_PAGINATOR_VIEW', 'pagination::tailwind'),
        'defaultSimpleView' => env('UTILS_PAGINATOR_SIMPLE_VIEW', 'pagination::simple-tailwind'),
    ],
];

About

Laravel Utils is a package that configure simple things, which we usually forget about in our projects.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages