contributte / di

:sparkles: Extra contrib to nette/di (@nette)
https://contributte.org/packages/contributte/di.html
MIT License
46 stars 9 forks source link

Autoload: Support wildcards in namespace and excludes #13

Closed martenb closed 5 years ago

martenb commented 5 years ago

It will be nice to do something like this:

autoload:
    resources:
        App\Controllers\*Controller:
            paths: [%appDir%/Controllers]
                        excludes: [App\Controllers\Legacy*Controller]
f3l1x commented 5 years ago

Hi @martenb. I would love it, but I think this will be supported directly in nette/di v3.

Take a look: https://github.com/nette/di/blob/master/src/DI/Extensions/SearchExtension.php

mabar commented 5 years ago

Yup, we could drop autoload extension with nette 3.

martenb commented 5 years ago

Ok, you're right, i forgot about this feature in nette 3..