headerx/laravel-legacy-loader

catch-all routing for use of vanilla php scripts in your laravel app.

v1.0.0 2022-02-23 20:46 UTC

This package is auto-updated.

Last update: 2024-04-13 00:43:50 UTC


README

Latest Version on Packagist GitHub Tests Action Status GitHub Code Style Action Status Total Downloads

Installation

You can install the package via composer:

composer require headerx/laravel-legacy-loader

You can publish the config file with:

php artisan vendor:publish --provider="HeaderX\LegacyLoader\LegacyLoaderServiceProvider" --tag="legacy-loader-config"

This is the contents of the published config file:

return [
    /**
    * Route prefix under which the php files are to be 
    * accessed. Additional routes are not needed,
    * files will be accessible via thier path.
    */
    'route_prefix' => env('LEGACY_ROUTE_PREFIX', 'legacy'),
    /**
     * Path to legacy php scripts
     * relative to base_path()
     */
    'file_path' => env('LEGACY_FILE_PATH', 'resources/legacy'),
    /**
     * If your legacy app has its own
     * authentication you will need
     * to publish config and add
     * your own middleware.
     */
    'middleware' => [
        'web',
        // 'auth',
    ],

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

Credits

License

The MIT License (MIT). Please see License File for more information.