On Sat, Aug 4, 2012 at 12:06 AM, Gerry - <[email protected]> wrote:
> Ok. I think I understand. I can use composer to do autoloading, thus
> elimating the getAutoloaderConfig() methods in modules?
>
Yes - if you're talking about private modules that are used only by you, or
you commit to _always_ using composer (today and in the future)
No - if your modules will be used in other projects (yours or public) or in
the future you might stop using composer. getAutoloaderConfig() registers
spl autoloader that are shipped with ZF2, so this method will always work
in plain PHP and ZF 2.0, 2.1, 2.2 etc. and maybe even in 3.0. Also there is
no harm in having both - if you installed the module via composer, composer
autoloader will be used. If the composer autoloader is not present (or
cannot find the class), ZF2 autoloader will come in to finish the job....
all that assuming you have had getAutoloaderConfig() present.
--
__
/.)\ +48 695 600 936
\(./ [email protected]