diff --git a/composer.json b/composer.json index 9bfd35a5..cf4cc320 100644 --- a/composer.json +++ b/composer.json @@ -24,6 +24,7 @@ "ext-intl": "*" }, "require-dev": { + "illuminate/contracts": "^11.0", "illuminate/routing": "^11.0", "illuminate/support": "^11.0", "larastan/larastan": "^2.9", @@ -32,6 +33,7 @@ "mockery/mockery": "^1.6", "orchestra/testbench": "^9.4", "overtrue/phplint": "^9.4", + "paragonie/random_compat": "^2.0", "php-cs-fixer/shim": "^3.64", "phpstan/phpstan": "^1.12", "phpstan/phpstan-mockery": "^1.1", diff --git a/composer.lock b/composer.lock index d777d360..ab594d69 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "cc08c395a49664ffd2ca6bff4b103ca6", + "content-hash": "3b04f370b0657c53b6b7092cffb4354c", "packages": [], "packages-dev": [ { @@ -3545,21 +3545,27 @@ }, { "name": "paragonie/random_compat", - "version": "v1.0.0", + "version": "v2.0.0", "source": { "type": "git", "url": "https://github.com/paragonie/random_compat.git", - "reference": "a1d9f267eb8b8ad560e54e397a5ed1e3b78097d1" + "reference": "321a59fed499a5624b0e40cb5c824ae6116e0c18" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/a1d9f267eb8b8ad560e54e397a5ed1e3b78097d1", - "reference": "a1d9f267eb8b8ad560e54e397a5ed1e3b78097d1", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/321a59fed499a5624b0e40cb5c824ae6116e0c18", + "reference": "321a59fed499a5624b0e40cb5c824ae6116e0c18", "shasum": "" }, "require": { "php": ">=5.2.0" }, + "require-dev": { + "phpunit/phpunit": "4.*|5.*" + }, + "suggest": { + "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + }, "type": "library", "autoload": { "files": [ @@ -3588,7 +3594,7 @@ "issues": "https://github.com/paragonie/random_compat/issues", "source": "https://github.com/paragonie/random_compat" }, - "time": "2015-09-07T01:49:23+00:00" + "time": "2016-03-18T17:17:33+00:00" }, { "name": "phar-io/manifest", diff --git a/demo/laravel/bootstrap/app.php b/demo/laravel/bootstrap/app.php index 58e985f8..88321d39 100644 --- a/demo/laravel/bootstrap/app.php +++ b/demo/laravel/bootstrap/app.php @@ -3,16 +3,20 @@ use Illuminate\Foundation\Application; use Illuminate\Foundation\Configuration\Exceptions; use Illuminate\Foundation\Configuration\Middleware; +use Illuminate\Support\Facades\Route; return Application::configure(basePath: dirname(__DIR__)) ->withRouting( web: __DIR__.'/../routes/web.php', commands: __DIR__.'/../routes/console.php', health: '/up', + then: function () { + Route::middleware('web')->group(base_path('routes/issues.php')); + }, ) ->withMiddleware(function (Middleware $middleware) { $middleware->web(append: [ - \App\Http\Middleware\HandleInertiaRequests::class, + App\Http\Middleware\HandleInertiaRequests::class, ]); }) ->withExceptions(function (Exceptions $exceptions) { diff --git a/demo/laravel/composer.json b/demo/laravel/composer.json index 39e771bf..be6bd05f 100644 --- a/demo/laravel/composer.json +++ b/demo/laravel/composer.json @@ -32,7 +32,8 @@ "nunomaduro/collision": "^8.0", "pestphp/pest": "^2.34", "pestphp/pest-plugin-laravel": "^2.3", - "spatie/laravel-ignition": "^2.4" + "spatie/laravel-ignition": "^2.4", + "spatie/ray": "^1.41" }, "autoload": { "psr-4": { @@ -49,13 +50,16 @@ "scripts": { "post-autoload-dump": [ "Illuminate\\Foundation\\ComposerScripts::postAutoloadDump", - "@php artisan package:discover --ansi" + "@php artisan package:discover --ansi", + "@php artisan flasher:install --symlink" ], "post-update-cmd": [ - "@php artisan vendor:publish --tag=laravel-assets --ansi --force" + "@php artisan vendor:publish --tag=laravel-assets --ansi --force", + "@php artisan flasher:install --symlink" ], "post-root-package-install": [ - "@php -r \"file_exists('.env') || copy('.env.example', '.env');\"" + "@php -r \"file_exists('.env') || copy('.env.example', '.env');\"", + "@php artisan flasher:install --symlink" ], "post-create-project-cmd": [ "@php artisan key:generate --ansi", diff --git a/demo/laravel/composer.lock b/demo/laravel/composer.lock index b497624b..94b05bd7 100644 --- a/demo/laravel/composer.lock +++ b/demo/laravel/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "6a5eb94d553bf800816057a2f860bceb", + "content-hash": "880310cf6d0fbcbfccd6273a5a22b25b", "packages": [ { "name": "brick/math", @@ -2490,7 +2490,7 @@ "dist": { "type": "path", "url": "../..", - "reference": "816529029b06b61897a4a0d482718be64319ddf8" + "reference": "8d0dff222474071fa534271bddd9e6f40a58ac93" }, "require": { "ext-intl": "*", @@ -2499,20 +2499,23 @@ "require-dev": { "illuminate/routing": "^11.0", "illuminate/support": "^11.0", - "larastan/larastan": "^2.9.5", + "larastan/larastan": "^2.9", "laravel/octane": "^2.3", - "livewire/livewire": "^3.3", - "mockery/mockery": "^1.6.11", - "orchestra/testbench": "^9.0.4", - "overtrue/phplint": "^9.2.0", - "php-cs-fixer/shim": "^3.54.0", - "phpstan/phpstan": "^1.10.67", - "phpstan/phpstan-mockery": "^1.1.2", - "phpstan/phpstan-symfony": "^1.3.12", - "phpunit/phpunit": "^10.5.13", + "livewire/livewire": "^3.5", + "mockery/mockery": "^1.6", + "orchestra/testbench": "^9.4", + "overtrue/phplint": "^9.4", + "paragonie/random_compat": "^2.0", + "php-cs-fixer/shim": "^3.64", + "phpstan/phpstan": "^1.12", + "phpstan/phpstan-mockery": "^1.1", + "phpstan/phpstan-phpunit": "^1.4", + "phpstan/phpstan-symfony": "^1.4", + "phpunit/phpunit": "^10.5", "psr/container": "^1.1|^2.0", - "rector/rector": "^1.0.4", - "rector/swiss-knife": "^0.2.2", + "rector/rector": "^1.2", + "rector/swiss-knife": "^0.2", + "spatie/ray": "^1.41", "symfony/config": "^7.0", "symfony/console": "^7.0", "symfony/dependency-injection": "^7.0", @@ -2520,8 +2523,8 @@ "symfony/http-kernel": "^7.0", "symfony/translation": "^7.0", "symfony/twig-bundle": "^7.0", - "symfony/ux-twig-component": "^2.14", - "symplify/monorepo-builder": "^11.2.20" + "symfony/ux-twig-component": "^2.19", + "symplify/monorepo-builder": "^11.2" }, "type": "library", "extra": { diff --git a/demo/laravel/routes/issues.php b/demo/laravel/routes/issues.php new file mode 100644 index 00000000..1392d843 --- /dev/null +++ b/demo/laravel/routes/issues.php @@ -0,0 +1,15 @@ +success('Your order has been placed successfully.'); + // Passing another success message with the view + return redirect('/issues/190/redirect')->with('success', 'Your order will be delivered in 3-5 business days.'); +}); + +Route::get('/issues/190/redirect', function () { + return view('welcome'); +}); diff --git a/demo/laravel/routes/web.php b/demo/laravel/routes/web.php index af17378f..af9b0907 100644 --- a/demo/laravel/routes/web.php +++ b/demo/laravel/routes/web.php @@ -1,23 +1,27 @@ timerProgressBar()->success('hello from Home Controller'); - // noty()->layout('topCenter')->success('hello from Home Controller'); - // notyf()->ripple(false)->warning('hello from Home Controller'); - // toastr()->positionClass('toast-bottom-left')->error('hello from Home Controller'); - // flash()->use('flasher')->success('hello from flasher factory'); - - // flash()->created(new Book('lord of the rings')); - // flash()->saved(new Book('harry potter')); - - session()->flash('success', 'this from laravel session flash'); - - return redirect('/redirect'); + sweetalert()->timerProgressBar()->success('Your account has been successfully created!'); + noty()->layout('topCenter')->success('Welcome back, John Doe!'); + notyf()->ripple(false)->warning('Your subscription is about to expire in 3 days.'); + toastr()->positionClass('toast-bottom-left')->error('Payment failed. Please try again.'); + flash()->use('flasher')->success('Your profile has been updated successfully.'); + flash()->created(new Book('The Great Gatsby')); + flash()->saved(new Book('1984')); + session()->flash('success', 'Your settings have been saved.'); + return view('welcome'); })->name('app_home'); Route::get('/redirect', function () { + session()->flash('success', 'You have been redirected successfully.'); + return redirect('/destination'); +}); + +Route::get('/destination', function () { return view('welcome'); }); diff --git a/demo/symfony/composer.json b/demo/symfony/composer.json index 45e397c6..0bed2a5a 100644 --- a/demo/symfony/composer.json +++ b/demo/symfony/composer.json @@ -61,7 +61,8 @@ "scripts": { "auto-scripts": { "cache:clear": "symfony-cmd", - "assets:install %PUBLIC_DIR%": "symfony-cmd" + "assets:install %PUBLIC_DIR%": "symfony-cmd", + "flasher:install": "symfony-cmd" }, "post-install-cmd": [ "@auto-scripts" @@ -80,6 +81,7 @@ } }, "require-dev": { + "spatie/ray": "^1.41", "symfony/maker-bundle": "^1.58" } } diff --git a/demo/symfony/composer.lock b/demo/symfony/composer.lock index 7adc515b..71fd6521 100644 --- a/demo/symfony/composer.lock +++ b/demo/symfony/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "fdaf8a5cf22e2d2c4ac44c9f4217ef9a", + "content-hash": "41085080102fac8108116dd57eb6f4b8", "packages": [ { "name": "composer/ca-bundle", @@ -161,7 +161,7 @@ "dist": { "type": "path", "url": "../..", - "reference": "816529029b06b61897a4a0d482718be64319ddf8" + "reference": "8d0dff222474071fa534271bddd9e6f40a58ac93" }, "require": { "ext-intl": "*", @@ -170,20 +170,23 @@ "require-dev": { "illuminate/routing": "^11.0", "illuminate/support": "^11.0", - "larastan/larastan": "^2.9.5", + "larastan/larastan": "^2.9", "laravel/octane": "^2.3", - "livewire/livewire": "^3.3", - "mockery/mockery": "^1.6.11", - "orchestra/testbench": "^9.0.4", - "overtrue/phplint": "^9.2.0", - "php-cs-fixer/shim": "^3.54.0", - "phpstan/phpstan": "^1.10.67", - "phpstan/phpstan-mockery": "^1.1.2", - "phpstan/phpstan-symfony": "^1.3.12", - "phpunit/phpunit": "^10.5.13", + "livewire/livewire": "^3.5", + "mockery/mockery": "^1.6", + "orchestra/testbench": "^9.4", + "overtrue/phplint": "^9.4", + "paragonie/random_compat": "^2.0", + "php-cs-fixer/shim": "^3.64", + "phpstan/phpstan": "^1.12", + "phpstan/phpstan-mockery": "^1.1", + "phpstan/phpstan-phpunit": "^1.4", + "phpstan/phpstan-symfony": "^1.4", + "phpunit/phpunit": "^10.5", "psr/container": "^1.1|^2.0", - "rector/rector": "^1.0.4", - "rector/swiss-knife": "^0.2.2", + "rector/rector": "^1.2", + "rector/swiss-knife": "^0.2", + "spatie/ray": "^1.41", "symfony/config": "^7.0", "symfony/console": "^7.0", "symfony/dependency-injection": "^7.0", @@ -191,8 +194,8 @@ "symfony/http-kernel": "^7.0", "symfony/translation": "^7.0", "symfony/twig-bundle": "^7.0", - "symfony/ux-twig-component": "^2.14", - "symplify/monorepo-builder": "^11.2.20" + "symfony/ux-twig-component": "^2.19", + "symplify/monorepo-builder": "^11.2" }, "type": "library", "extra": { @@ -3914,6 +3917,66 @@ } ], "packages-dev": [ + { + "name": "brick/math", + "version": "0.12.1", + "source": { + "type": "git", + "url": "https://github.com/brick/math.git", + "reference": "f510c0a40911935b77b86859eb5223d58d660df1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/brick/math/zipball/f510c0a40911935b77b86859eb5223d58d660df1", + "reference": "f510c0a40911935b77b86859eb5223d58d660df1", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "require-dev": { + "php-coveralls/php-coveralls": "^2.2", + "phpunit/phpunit": "^10.1", + "vimeo/psalm": "5.16.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Brick\\Math\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Arbitrary-precision arithmetic library", + "keywords": [ + "Arbitrary-precision", + "BigInteger", + "BigRational", + "arithmetic", + "bigdecimal", + "bignum", + "bignumber", + "brick", + "decimal", + "integer", + "math", + "mathematics", + "rational" + ], + "support": { + "issues": "https://github.com/brick/math/issues", + "source": "https://github.com/brick/math/tree/0.12.1" + }, + "funding": [ + { + "url": "https://github.com/BenMorel", + "type": "github" + } + ], + "time": "2023-11-29T23:19:16+00:00" + }, { "name": "doctrine/inflector", "version": "2.0.10", @@ -4063,6 +4126,385 @@ }, "time": "2024-03-05T20:51:40+00:00" }, + { + "name": "ramsey/collection", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/ramsey/collection.git", + "reference": "a4b48764bfbb8f3a6a4d1aeb1a35bb5e9ecac4a5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ramsey/collection/zipball/a4b48764bfbb8f3a6a4d1aeb1a35bb5e9ecac4a5", + "reference": "a4b48764bfbb8f3a6a4d1aeb1a35bb5e9ecac4a5", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "require-dev": { + "captainhook/plugin-composer": "^5.3", + "ergebnis/composer-normalize": "^2.28.3", + "fakerphp/faker": "^1.21", + "hamcrest/hamcrest-php": "^2.0", + "jangregor/phpstan-prophecy": "^1.0", + "mockery/mockery": "^1.5", + "php-parallel-lint/php-console-highlighter": "^1.0", + "php-parallel-lint/php-parallel-lint": "^1.3", + "phpcsstandards/phpcsutils": "^1.0.0-rc1", + "phpspec/prophecy-phpunit": "^2.0", + "phpstan/extension-installer": "^1.2", + "phpstan/phpstan": "^1.9", + "phpstan/phpstan-mockery": "^1.1", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5", + "psalm/plugin-mockery": "^1.1", + "psalm/plugin-phpunit": "^0.18.4", + "ramsey/coding-standard": "^2.0.3", + "ramsey/conventional-commits": "^1.3", + "vimeo/psalm": "^5.4" + }, + "type": "library", + "extra": { + "captainhook": { + "force-install": true + }, + "ramsey/conventional-commits": { + "configFile": "conventional-commits.json" + } + }, + "autoload": { + "psr-4": { + "Ramsey\\Collection\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ben Ramsey", + "email": "ben@benramsey.com", + "homepage": "https://benramsey.com" + } + ], + "description": "A PHP library for representing and manipulating collections.", + "keywords": [ + "array", + "collection", + "hash", + "map", + "queue", + "set" + ], + "support": { + "issues": "https://github.com/ramsey/collection/issues", + "source": "https://github.com/ramsey/collection/tree/2.0.0" + }, + "funding": [ + { + "url": "https://github.com/ramsey", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/ramsey/collection", + "type": "tidelift" + } + ], + "time": "2022-12-31T21:50:55+00:00" + }, + { + "name": "ramsey/uuid", + "version": "4.7.6", + "source": { + "type": "git", + "url": "https://github.com/ramsey/uuid.git", + "reference": "91039bc1faa45ba123c4328958e620d382ec7088" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/ramsey/uuid/zipball/91039bc1faa45ba123c4328958e620d382ec7088", + "reference": "91039bc1faa45ba123c4328958e620d382ec7088", + "shasum": "" + }, + "require": { + "brick/math": "^0.8.8 || ^0.9 || ^0.10 || ^0.11 || ^0.12", + "ext-json": "*", + "php": "^8.0", + "ramsey/collection": "^1.2 || ^2.0" + }, + "replace": { + "rhumsaa/uuid": "self.version" + }, + "require-dev": { + "captainhook/captainhook": "^5.10", + "captainhook/plugin-composer": "^5.3", + "dealerdirect/phpcodesniffer-composer-installer": "^0.7.0", + "doctrine/annotations": "^1.8", + "ergebnis/composer-normalize": "^2.15", + "mockery/mockery": "^1.3", + "paragonie/random-lib": "^2", + "php-mock/php-mock": "^2.2", + "php-mock/php-mock-mockery": "^1.3", + "php-parallel-lint/php-parallel-lint": "^1.1", + "phpbench/phpbench": "^1.0", + "phpstan/extension-installer": "^1.1", + "phpstan/phpstan": "^1.8", + "phpstan/phpstan-mockery": "^1.1", + "phpstan/phpstan-phpunit": "^1.1", + "phpunit/phpunit": "^8.5 || ^9", + "ramsey/composer-repl": "^1.4", + "slevomat/coding-standard": "^8.4", + "squizlabs/php_codesniffer": "^3.5", + "vimeo/psalm": "^4.9" + }, + "suggest": { + "ext-bcmath": "Enables faster math with arbitrary-precision integers using BCMath.", + "ext-gmp": "Enables faster math with arbitrary-precision integers using GMP.", + "ext-uuid": "Enables the use of PeclUuidTimeGenerator and PeclUuidRandomGenerator.", + "paragonie/random-lib": "Provides RandomLib for use with the RandomLibAdapter", + "ramsey/uuid-doctrine": "Allows the use of Ramsey\\Uuid\\Uuid as Doctrine field type." + }, + "type": "library", + "extra": { + "captainhook": { + "force-install": true + } + }, + "autoload": { + "files": [ + "src/functions.php" + ], + "psr-4": { + "Ramsey\\Uuid\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A PHP library for generating and working with universally unique identifiers (UUIDs).", + "keywords": [ + "guid", + "identifier", + "uuid" + ], + "support": { + "issues": "https://github.com/ramsey/uuid/issues", + "source": "https://github.com/ramsey/uuid/tree/4.7.6" + }, + "funding": [ + { + "url": "https://github.com/ramsey", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/ramsey/uuid", + "type": "tidelift" + } + ], + "time": "2024-04-27T21:32:50+00:00" + }, + { + "name": "spatie/backtrace", + "version": "1.6.2", + "source": { + "type": "git", + "url": "https://github.com/spatie/backtrace.git", + "reference": "1a9a145b044677ae3424693f7b06479fc8c137a9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/backtrace/zipball/1a9a145b044677ae3424693f7b06479fc8c137a9", + "reference": "1a9a145b044677ae3424693f7b06479fc8c137a9", + "shasum": "" + }, + "require": { + "php": "^7.3|^8.0" + }, + "require-dev": { + "ext-json": "*", + "laravel/serializable-closure": "^1.3", + "phpunit/phpunit": "^9.3", + "spatie/phpunit-snapshot-assertions": "^4.2", + "symfony/var-dumper": "^5.1" + }, + "type": "library", + "autoload": { + "psr-4": { + "Spatie\\Backtrace\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Freek Van de Herten", + "email": "freek@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + } + ], + "description": "A better backtrace", + "homepage": "https://github.com/spatie/backtrace", + "keywords": [ + "Backtrace", + "spatie" + ], + "support": { + "source": "https://github.com/spatie/backtrace/tree/1.6.2" + }, + "funding": [ + { + "url": "https://github.com/sponsors/spatie", + "type": "github" + }, + { + "url": "https://spatie.be/open-source/support-us", + "type": "other" + } + ], + "time": "2024-07-22T08:21:24+00:00" + }, + { + "name": "spatie/macroable", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/spatie/macroable.git", + "reference": "ec2c320f932e730607aff8052c44183cf3ecb072" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/macroable/zipball/ec2c320f932e730607aff8052c44183cf3ecb072", + "reference": "ec2c320f932e730607aff8052c44183cf3ecb072", + "shasum": "" + }, + "require": { + "php": "^8.0" + }, + "require-dev": { + "phpunit/phpunit": "^8.0|^9.3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Spatie\\Macroable\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Freek Van der Herten", + "email": "freek@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + } + ], + "description": "A trait to dynamically add methods to a class", + "homepage": "https://github.com/spatie/macroable", + "keywords": [ + "macroable", + "spatie" + ], + "support": { + "issues": "https://github.com/spatie/macroable/issues", + "source": "https://github.com/spatie/macroable/tree/2.0.0" + }, + "time": "2021-03-26T22:39:02+00:00" + }, + { + "name": "spatie/ray", + "version": "1.41.2", + "source": { + "type": "git", + "url": "https://github.com/spatie/ray.git", + "reference": "c44f8cfbf82c69909b505de61d8d3f2d324e93fc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/spatie/ray/zipball/c44f8cfbf82c69909b505de61d8d3f2d324e93fc", + "reference": "c44f8cfbf82c69909b505de61d8d3f2d324e93fc", + "shasum": "" + }, + "require": { + "ext-curl": "*", + "ext-json": "*", + "php": "^7.3|^8.0", + "ramsey/uuid": "^3.0|^4.1", + "spatie/backtrace": "^1.1", + "spatie/macroable": "^1.0|^2.0", + "symfony/stopwatch": "^4.0|^5.1|^6.0|^7.0", + "symfony/var-dumper": "^4.2|^5.1|^6.0|^7.0.3" + }, + "require-dev": { + "illuminate/support": "6.x|^8.18|^9.0", + "nesbot/carbon": "^2.63", + "pestphp/pest": "^1.22", + "phpstan/phpstan": "^1.10", + "phpunit/phpunit": "^9.5", + "rector/rector": "^0.19.2", + "spatie/phpunit-snapshot-assertions": "^4.2", + "spatie/test-time": "^1.2" + }, + "bin": [ + "bin/remove-ray.sh" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.x-dev" + } + }, + "autoload": { + "files": [ + "src/helpers.php" + ], + "psr-4": { + "Spatie\\Ray\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Freek Van der Herten", + "email": "freek@spatie.be", + "homepage": "https://spatie.be", + "role": "Developer" + } + ], + "description": "Debug with Ray to fix problems faster", + "homepage": "https://github.com/spatie/ray", + "keywords": [ + "ray", + "spatie" + ], + "support": { + "issues": "https://github.com/spatie/ray/issues", + "source": "https://github.com/spatie/ray/tree/1.41.2" + }, + "funding": [ + { + "url": "https://github.com/sponsors/spatie", + "type": "github" + }, + { + "url": "https://spatie.be/open-source/support-us", + "type": "other" + } + ], + "time": "2024-04-24T14:21:46+00:00" + }, { "name": "symfony/maker-bundle", "version": "v1.59.1", @@ -4154,6 +4596,68 @@ } ], "time": "2024-05-06T03:59:59+00:00" + }, + { + "name": "symfony/stopwatch", + "version": "v7.0.8", + "source": { + "type": "git", + "url": "https://github.com/symfony/stopwatch.git", + "reference": "e4a0d6fef3dd428ca23172e62d1d863f6f25d541" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/e4a0d6fef3dd428ca23172e62d1d863f6f25d541", + "reference": "e4a0d6fef3dd428ca23172e62d1d863f6f25d541", + "shasum": "" + }, + "require": { + "php": ">=8.2", + "symfony/service-contracts": "^2.5|^3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Stopwatch\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides a way to profile code", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/stopwatch/tree/v7.0.8" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-05-31T14:55:39+00:00" } ], "aliases": [], diff --git a/taskfile.dist.yml b/taskfile.dist.yml index 08acc7cb..10e9330c 100644 --- a/taskfile.dist.yml +++ b/taskfile.dist.yml @@ -1,33 +1,19 @@ version: '3' tasks: - install: - desc: "๐Ÿ“ฆ Install project dependencies using Composer." - cmds: - - composer install - aliases: - - i - - in - update: desc: "๐Ÿ”„ Update project dependencies and rebuild assets." cmds: - composer update --prefer-lowest -W - npm run ncu - npm install --force - - task: build + - npm run build - task: lint + - task: docs:build aliases: - u - up - require: - desc: "โž• Add a new Composer dependency to the project." - cmds: - - composer require {{ .CLI_ARGS }} - aliases: - - req - lint: desc: "๐Ÿ” Analyze code for potential errors and coding standards violations." cmds: @@ -35,65 +21,28 @@ tasks: - php vendor/bin/php-cs-fixer fix - php vendor/bin/phpstan analyse --memory-limit=-1 - composer validate --strict - - php vendor/bin/phplint - find src/ -name "composer.json" -exec composer validate --strict {} \; - - task: test + - php vendor/bin/phplint + - php vendor/bin/phpunit aliases: - pint - check - validate - test: - desc: "โœ… Run PHPUnit tests to ensure code correctness." + docs:build: + desc: "๐Ÿ“˜ Build the documentation." + dir: docs/ cmds: - - php vendor/bin/phpunit - aliases: - - tests - - phpunit - - unit - - coverage: - desc: "๐Ÿ“Š Generate code coverage reports." - cmds: - - vendor/bin/phpunit --coverage-html coverage - aliases: - - cov - - cover + - npm install --force + - npm run build security: desc: "๐Ÿ” Check for security vulnerabilities in dependencies." cmds: - symfony security:check - aliases: - - seccheck - - sec - - clean: - desc: "๐Ÿงน Clean up generated files and reset the environment." - cmds: - - rm -rf vendor/ composer.lock node_modules/ package-lock.json - aliases: - - cl - - cleanup - - build: - desc: "๐Ÿ—๏ธ Build project assets." - cmds: - - npm run build - aliases: - - b - - watch: - desc: "๐Ÿ‘€ Watch for file changes and rebuild assets automatically." - cmds: - - npm run watch - aliases: - - w release: desc: "๐Ÿท๏ธ Prepare and tag a new release." cmds: - php bin/split - php bin/release {{.CLI_ARGS}} - aliases: - - rel