codeguy/Slim — pull request #403 by mnlg (2012-08-30 16:38:56+00:00)
Title: Array access

This is an initial implementation for #398.

So far what it does is implement ArrayAccess in the Slim class and make the Request, Response, Environment and Router array accessible.

$app = new \Slim\Slim();
$app['response']['status'] = '500';

Maybe adding the Slim settings and the application middleware to the array access would be cool too, something like the Pimple's share method might be also useful.

I kind of like this DI container idea and I think it would allow Slim to evolve in a much more modular framework, what do you guys think?