From 6f025006861c722ad662b2ec8ec05e712a228086 Mon Sep 17 00:00:00 2001 From: Imani Manyara Date: Sat, 3 Oct 2026 15:16:21 -0400 Subject: [PATCH] Rename the quick start to Quick start guide and usage The README standard now splits the section into Getting started, the setup a fresh install needs before the first call, and Usage. Every command, tag and env key shown was checked against the package's own provider, config or CLI. --- README.md | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8a50f41..ba6225f 100644 --- a/README.md +++ b/README.md @@ -31,7 +31,25 @@ use Simtabi\Laranail\Confetti\Facades\Confetti; Confetti::realistic()->shoot(); ``` -## Quick start +## Quick start guide and usage + +### Getting started + +1. Put the runtime on your pages, once. Use the `` component shown in Install, or let the middleware append it to every HTML response: + + ```dotenv + CONFETTI_AUTO_INJECT=true + ``` + +2. Check the setup. It reports the bundle, the asset delivery mode and any Content-Security-Policy directives you need: + + ```bash + php artisan laranail::confetti.doctor + ``` + +3. Optionally, `php artisan laranail::confetti.install` writes `config/laranail/confetti.php`; every setting has a working default. + +### Usage ```php use Simtabi\Laranail\Confetti\Facades\Confetti; @@ -46,6 +64,15 @@ public function store(StoreOrderRequest $request) } ``` +Several bursts at once, with shared options said once: + +```php +Confetti::colors('#bb0000', '#ffffff') + ->left()->count(100)->then() + ->right()->count(100) + ->shoot(); +``` + The full walkthrough is in [Getting started](docs/getting-started.md); everything else is in the [documentation index](#documentation). ## Documentation