$ show Sylius/Sylius
Sylius is a mature open-source e-commerce framework built on Symfony, organized as a monorepo of decoupled PHP bundles and domain components. In production it powers multi-channel, multi-currency, multi-locale storefronts with product catalogs, carts and checkout, order management, payments via Payum, taxes, shipping, promotions and coupons, inventory, customer accounts, and an admin panel. It exposes a JSON:API via API Platform for headless commerce, a Twig/Stimulus storefront, an admin interface, and CLI commands for installation, user management, and maintenance. The domain logic lives primarily in the Sylius Component and Bundle layers, with UI and API layers acting as adapters over shared services.
The LLM identified 3 files worth highlighting for reuse:
A self-contained state machine abstraction that unifies Symfony Workflow and winzou state machine behind one interface. It supports composing multiple state machines, applying transitions by name, and reporting execution exceptions. The package has its own composer.json, tests, and DI integration, making it genuinely extractable for any PHP/Symfony project that needs to decouple domain code from a specific workflow engine.
A generic Symfony DI compiler pass that collects tagged services with priority and assembles them into ordered composite collections. This is reusable across any Symfony application that needs pluggable, ordered service stacks without hard-coded service locators. It demonstrates non-obvious container manipulation and is a core reason Sylius's extension points stay clean despite the large number of registered services.
A fluent request builder for API acceptance tests, decoupling Behat step definitions from HTTP transport details. It supports JSON:API content types, query parameters, authentication context, and step-by-step request construction. Although built for Sylius's Behat suite, the pattern is directly reusable in other API testing harnesses that need maintainable, typed HTTP request construction.