# CC Soccer D11 - External Dependencies

**Track PHP libraries and packages installed via Composer**

Last Updated: January 26, 2025

---

## PHP Libraries (via Composer)

### TCPDF Library

**Installed:** January 26, 2025  
**Version:** ~6.7  
**Package:** tecnickcom/tcpdf  
**Why:** PDF generation for reports and schedule exports

```bash
ddev composer require tecnickcom/tcpdf
```

**Used By:**
- City Payment Report system (`CityReportService.php`)
- Schedule PDF exports (`SchedulePdfService.php`)
- Base PDF service (`PdfService.php`)

**Configuration Notes:**
- We use TCPDF library directly (not the Drupal tcpdf module)
- Provides better control over PDF generation
- No headers/footers enabled
- All PDFs use landscape orientation
- Custom styling via PdfService base class

**Documentation:**
- Official: https://tcpdf.org/
- GitHub: https://github.com/tecnickcom/TCPDF

**Verify Installation:**
```bash
ddev composer show tecnickcom/tcpdf
```

---

## Installation for New Developers

After cloning the repo, run:

```bash
# Install all composer dependencies
ddev composer install

# Clear Drupal cache
ddev drush cr
```

This will install:
- All Drupal modules from composer.json
- All PHP libraries (including TCPDF)
- All dependencies

---

## Notes

- Always use `ddev composer install` after pulling, not `ddev composer update`
- `composer.json` and `composer.lock` are both committed to git
- `composer.lock` ensures everyone gets the exact same versions
- Never commit the `vendor/` directory (it's in .gitignore)

---
