Skip to content

Releases: PHP-DI/Silex-Bridge

1.5.2

17 Dec 20:02
Compare
Choose a tag to compare

#23, #25: ControllerResolver fails when parameter with default value is not provided

1.5.1

10 Jun 06:07
Compare
Choose a tag to compare
  • #19 & #20: Fix short-circuiting the controller from a before application/route middleware

2.0.0-beta1

02 Jun 12:22
Compare
Choose a tag to compare
2.0.0-beta1 Pre-release
Pre-release

First beta of the future 2.0 release.

The main change is the support for Silex 2 (see #17).

1.5.0

21 Mar 21:24
Compare
Choose a tag to compare
  • #15 & #16: Dependency injection in middleware and parameter converter parameters, by @felixfbecker

1.4.0

04 Feb 12:21
Compare
Choose a tag to compare

In other words, this brings the resolution logic of enhanced controllers as services to all callbacks in Silex.

Example of a middleware resolved by PHP-DI:

class AuthMiddleware
{
    public function beforeRoute(Request $request, Application $app)
    {
        // ...
    }
}

$app->before([AuthMiddleware::class, 'beforeRoute']);

You can view the documentation here.

1.3.0

07 Nov 22:01
Compare
Choose a tag to compare

PR #8 by @jdreesen:

  • #7 improved compatibility with ServiceControllerServiceProvider
  • support injecting the Application object by type hint
  • support injecting the current Request object by type hint (additionally to inject by name)

1.2.1

02 Sep 08:46
Compare
Choose a tag to compare

#5 - Bugfix for better compatibility with ServiceControllerServiceProvider

1.2.0

01 Sep 09:47
Compare
Choose a tag to compare

Big internal simplification which should lead to better performances, less overhead and full compatibility with all Silex service providers.

1.1.1

31 Jul 10:11
Compare
Choose a tag to compare

The container can now be injected by type-hinting Interop\Container\ContainerInterface in controllers.

$app->post('/', function (ContainerInterface $container) {
    // ...
});

1.1.0

31 Jul 08:54
Compare
Choose a tag to compare
  • The request object can now be injected in controllers by adding a parameter named $request (type-hint is optional)

    $app->post('/register/{name}', function (Request $request, Mailer $mailer) {
        // ...
    });
  • Query string parameters and POST parameters where previously injected in controllers (if a parameter had the same name). This was bad design, very unconventional and surprising behavior (probably unused) and creates a lot of potential for applications to break, so this has been removed. Inject the whole request to handle those cases.