From ee65de7d8b345fb4031e7ec5c7e436718c492184 Mon Sep 17 00:00:00 2001 From: Jan Klattenhoff Date: Fri, 28 Feb 2025 12:49:20 +0100 Subject: [PATCH] docs: add CLAUDE.md project reference documentation --- CLAUDE.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 CLAUDE.md diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..a4285fc --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,28 @@ +# CLAUDE.md - Abiball Project Reference + +## Commands +- Setup: `composer install` +- Run server: `symfony server:start` or `php -S localhost:8000 -t public/` +- Clear cache: `bin/console cache:clear` +- Build assets: `bin/console importmap:install` +- Compile Tailwind: `bin/console tailwind:build` and `bin/console tailwind:build --watch` +- Run specific test: `bin/phpunit tests/path/to/TestFile.php` +- Database migrations: `bin/console doctrine:migrations:migrate` + +## Code Style +- PHP >= 8.2, Symfony 7.2 +- PSR-4 autoloading (`App\` namespace in `src/`) +- Use strict typing (`declare(strict_types=1)`) +- Controllers in `src/Controller/` with suffix `Controller` +- Entities in `src/Entity/` with repositories in `src/Repository/` +- Forms in `src/Form/` with suffix `Type` +- Services in `src/Service/` with dependency injection +- Use Symfony data objects for form handling +- Twig templates in `templates/` with directories matching controller names +- JavaScript in `assets/` with Stimulus controllers for dynamic components +- CSS using Tailwind utility classes + +## Error Handling +- Use appropriate Symfony exceptions +- Handle form submissions with proper validation +- Use flasher-noty for user notifications \ No newline at end of file