app/holds Laravel domain logic (models, Livewire actions, policies); keep new PHP classes under relevant domain subfolders.routes/web.phpandroutes/api.phpdefine trainer- and API-facing endpoints; pair route changes with matching Livewire or controller updates.resources/viewscontains Blade layouts and Livewire views;resources/jsstores the Vue-based SoccerDraw tool and shared JS.database/migrationsanddatabase/seedersmanage schema and fixtures; updatedatabase/factorieswhen persisting new models.tests/Featureandtests/Unitcover HTTP flows and pure logic respectively; mirror new features with dedicated specs.
composer install/npm installinstall PHP and Node dependencies.php artisan migrate --seedbrings the SQLite dev database in sync with baseline seed data.php artisan key:generaterefreshes the application key after cloning../vendor/bin/pestruns the full PHP test suite; pass--groupto target tagged tests.npm run devlaunches the Vite dev server for Tailwind and Vue assets;npm run buildproduces production bundles.
- Follow PSR-12 with 4-space indentation for PHP; keep Livewire component classes in PascalCase and blade templates in kebab-case (e.g.,
player-practice-rating.blade.php). - Vue single-file components live under
resources/js/componentsin PascalCase; export default names must match filenames. - Favor Tailwind utility classes; custom styles belong in
resources/css/app.css. - Run Laravel Pint (
./vendor/bin/pint) before submitting to ensure consistent formatting.
- Pest is the default framework; describe scenarios with
it()blocks and snake_case test function names. - Co-locate factories in
database/factoriesand refresh the database via Pest'sRefreshDatabasetrait when tests mutate state. - Add end-to-end checks for new Livewire flows in
tests/Feature; isolate pure services undertests/Unit.
- Use conventional prefixes observed in history (
feat:,fix:,refactor:) followed by imperative summaries. - Reference issue IDs or Trello cards in the body when available, and list any migrations or breaking changes.
- PRs should outline context, screenshots for UI changes, seeded data required, and the test commands executed (
./vendor/bin/pest,npm run build).
- Copy
.env.exampleto.env, set database credentials, and point todatabase/database.sqlitefor local builds. - Storage symlinks (
php artisan storage:link) are required before serving uploaded media. - Avoid committing
.env,storage/, or generated PDFs; rely on Git LFS only when explicitly requested.