ruwork/reform-bundle
A Symfony bundle that integrates Ruwork's Reform form library into your application, providing configuration and service wiring for building, validating, and processing forms with less boilerplate. It is aimed at projects already using Reform and Symfony's dependency injection and container conventi...
composer require ruwork/reform-bundle, then immediately pin the resolved version and commit composer.lock. The latest tagged release is now 0.2.0 (previously 0.1.x from 2018-07-09); the package is still archived, so treat it as vendored code, not a live dependency. Note that on a 0.x line Composer treats minor bumps as potentially breaking — ^0.1 will not resolve 0.2.0, and ^0.2 permits future 0.2.x surprises. Pin exactly (0.2.0), not a range.README.md (usually the only docs), DependencyInjection/Configuration.php (the real API of the bundle — the config tree is the only authoritative description of options), DependencyInjection/ReformExtension.php (what services get registered), then Form/ and Resources/views/Form/ (the day-to-day surface). As of 0.2.0 there is a new file to read closely: Resources/views/Form/reform_bootstrap_4_layout.html.twig — the entire delta of this release.extra.symfony block in its composer.json, Flex will not auto-register it. Add Ruwork\ReformBundle\ReformBundle::class => ['all' => true] to config/bundles.php (or new Ruwork\ReformBundle\ReformBundle() in a legacy AppKernel).bin/console debug:container | grep -i reform, bin/console debug:form, and bin/console debug:config reform. This tells you in seconds whether the contribution is form types, type extensions, Twig themes, or services — often faster than reading 2018-era source.debug:form App\Form\FooType. (2) The Bootstrap 4 form theme. Add reform_bootstrap_4_layout.html.twig to twig.form_themes, or apply it per-form with {% form_theme form 'reform_bootstrap_4_layout.html.twig' %}, then render a form and diff the markup against plain bootstrap_4_layout.html.twig to see what the bundle actually changes. That diff is the fastest way to understand the release.form.type_extension tag. Confirm the tag is declared in Resources/config/services.xml or via autoconfigure; if you need to override the extension, decorate the service rather than editing vendor code.reform_bootstrap_4_layout.html.twig into global twig.form_themes on day one. Register it on a single form ({% form_theme form ... %}) or a single template, compare output, then promote it globally once you know it does not fight your existing theme stack.bootstrap_4_layout.html.twig (Twig Bridge / symfony/form), e.g. via {% use %}. Check the file header for {% use ... %} and {% block ... %} overrides: whether it extends or replaces Bootstrap 4 rendering determines whether you must also register bootstrap_4_layout.html.twig and keep symfony/twig-bridge at a compatible version. The 2018-era parent theme has changed shape since; block names may no longer exist.config/packages/reform.yaml (or app/config/config.yml for pre-Flex apps) using the node names from Configuration.php. Only override keys you can see in the tree — there are no docs to fall back on.reform_bootstrap_4_layout.html.twig to templates/bundles/ReformBundle/Form/reform_bootstrap_4_layout.html.twig and edit there — the least invasive way to tweak rendering without forking. Note the path includes the Form/ segment, matching Resources/views/Form/.composer.json repositories: [{type: vcs, url: …}], or (b) copy the bundle into src/ReformBundle, drop the vendor requirement, and register it locally. Option (b) is usually cheaper for a 0-star, 0-dependent package — and with 0.2.0 adding exactly one Twig file, copying just that template into templates/ and skipping the bundle entirely is a serious option.App\Form\… types or a decorator, and keep a thin templates/form/reform_theme.html.twig that does {% use 'reform_bootstrap_4_layout.html.twig' %} so swapping the source later is a one-line change.$this->createForm(...)->createView()) — for unmaintained bundles, this catches signature breaks on Symfony upgrades. Add a rendered-HTML assertion on the form view now that a theme ships, otherwise a silently-missing/renamed block goes unnoticed.#[AsDecorator] or a compiler pass to intercept the bundle's services instead of editing them; this survives re-installs and keeps the diff to vendor code at zero.^0.1. Read the release as "one new template, unknown compatibility": diff the bundle tree between 0.1.x and 0.2.0 (composer diff, or install both in a scratch app) to confirm the theme is the only change and nothing in Form/ or DependencyInjection/ moved.composer audit and pin the exact version. The 0.2.0 tag should not be read as a sign of renewed maintenance.form-row classes) will be wrong. Either override the theme's blocks wholesale or skip it — Bootstrap 5 form theming is better served by Symfony's built-in bootstrap_5_layout.html.twig.twig.form_themes are searched in order; a bundle theme registered via Flex/config can be shadowed by another bundle's (EasyAdmin, etc.). Verify with bin/console debug:twig --filter=reform and by checking twig.form_themes in debug:config twig, not by assuming the file is reachable because it is installed.FormTypeInterface signatures, ChoiceLoaderInterface, ContainerAware* base classes, TreeBuilder/Configuration APIs, and — now relevant — Twig form theme block names and {% use %} semantics. Use composer why-not symfony/framework-bundle to see what is actually blocking an upgrade.each(), or missing return types. Enable E_ALL, check for #[\ReturnTypeWillChange] needs, and lint the bundle's PHP with the same version as your app before trusting it.debug:container --tag=form.type_extension and lint:container to confirm registration, and check _defaults: { public: false } in the bundle's service config. Templates fail quietly in the same way — a typo'd theme name is a Twig\Error\LoaderError at render time, not at boot.Configuration.php. After changing YAML, verify with bin/console debug:config reform rather than assuming the key was accepted; unknown keys are rejected only if the tree is strict. The new template adds no config surface — if a release note is a file, there is nothing to configure.composer update.symfony/ux components, or a small internal helper usually cover the same ground with maintenance guarantees. The 0.2.0 template is a candidate to copy into your own templates/ and disown.How can I help you explore Laravel packages today?