Cursor rule Cursor
Composer plugin symkit/bundle-ai-kit — Cursor-only sync.
AI rules and optional skills for building Symfony bundles with best practices: SOLID, AbstractBundle, Contract pattern, and quality tooling (PHPStan 9, GrumPHP, Infection, Deptrac, CI).
Cursor rule Cursor
Composer plugin symkit/bundle-ai-kit — Cursor-only sync.
Cursor rule Cursor
Conventions for writing .mdc rule and skill files distributed by the plugin.
Cursor rule Cursor
Strict PHP code style for Composer plugin source code.
Cursor rule Cursor
Quality tooling configuration and CI pipeline for the Composer plugin.
Cursor rule Cursor
Testing patterns for the Composer plugin test suite.
Cursor rule
API Platform: Resources, providers/processors, serialization, validation, Problem Details (optional in bundles).
Cursor rule
Symfony native API: MapRequestPayload, MapQueryString, Serializer groups, RFC 7807 (bundle controllers).
Cursor rule
Bundle architecture: Extension, services, public Contract API, tests, Flex — adapt to existing patterns.
Cursor rule
Caching: HTTP cache, app cache pools, decorator, tag invalidation, stampede, ESI.
Cursor rule
PHP 8.2+ coding: stricttypes, final, SOLID, DI, TaggedIterator, iterables, no dump/dd.
Cursor rule
Console commands: ProgressBar, SymfonyStyle, scheduling, exit codes, CommandTester.
Cursor rule
Doctrine in bundles: entities, mapping (XML), repos — only when the bundle persists data.
Cursor rule
DTOs: immutability, context-based naming, validation at boundary, mapping, no public setters.
Cursor rule
Error handling: custom exceptions, ExceptionListener, RFC 7807 Problem Details, errors.
Cursor rule
Forms: DTO binding, FormType, EventSubscriber, DataTransformer (bundle FormTypes).
Cursor rule
Frontend: Stimulus, Turbo, Twig/Live Components, AssetMapper (bundle assets/templates).
Cursor rule
HTTP Client: scoped clients, retry, rate limiting, SSRF prevention, MockHttpClient.
Cursor rule
For logging and observability conventions, see observability.mdc.
Cursor rule
Mailer/Notifier: templated emails, transports, async Messenger dispatch, testing.
Cursor rule
Messenger CQRS: commands, handlers, buses, transports, stamps, idempotence, failure handling.
Cursor rule
Observability: PSR-3, structured logging, LogSubscriber, Monolog, FingersCrossed, PII masking.
Cursor rule
Quality pipeline: make ci/tests/quality, PHPStan L9, Deptrac, GrumPHP (bundle package repos).
Cursor rule
Security: JWT, Voters, rate limiting, CORS, OWASP API Top 10 (bundle-exposed endpoints).
Cursor rule
Serializer: normalizers, groups, context builders, circular refs, discriminator map.