Commands
Prefer a named script over calling a vendor binary. Run PHP scripts with composer and JS scripts with npm run.
PHP
| Command | Use it to |
|---|---|
composer test | Run PHPUnit with readable output. Add -- --filter name while iterating. |
composer test:parallel | Run the whole suite with Paratest. Run it before you push. |
composer test:coverage | Build an HTML coverage report in build/coverage. |
composer phpstan | Run static analysis at level 8. |
composer rector | Apply automated refactors. |
composer style:fix | Format PHP with Pint. |
composer switch:l10 to switch:l13 | Install a specific Laravel major. |
Workbench
| Command | Use it to |
|---|---|
composer build | Build the workbench app. |
composer serve | Build it and serve it on ports 8000 and 8001. |
composer dev | Run composer serve and the Vite dev server together. |
composer nimbus | Run a Testbench command against the workbench. |
JavaScript
| Command | Use it to |
|---|---|
npm run style:check | Check the theme rules and run ESLint. |
npm run style:fix | Apply the ESLint fixes. |
npm run check:theme | Check that the theme preset reads tokens only. |
npm run type:check | Type check with vue-tsc. |
npm run test:run | Run Vitest once. |
npm test | Run Vitest in watch mode. |
npm run dev | Start the Vite dev server. |
End to end
| Command | Use it to |
|---|---|
npm run test:e2e | Run the Playwright specs in tests/E2E. They start or reuse the workbench servers. |
npm run test:e2e:ui | Open the Playwright UI. |
Generated types
| Command | Use it to |
|---|---|
php bin/intellisense | Regenerate the TypeScript interfaces in resources/js/interfaces/generated. Run it after you change a backend shape that the frontend reads. |
Never edit the generated folder by hand.
Build scripts
Do not run npm run build or npm run build:dev for a pull request. The release workflow builds and commits resources/dist.
The finalize task skill covers which checks to run for a given change.