plugin-scaffold icon indicating copy to clipboard operation
plugin-scaffold copied to clipboard

Examples of autoloading and namespacing classes?

Open tamara-m opened this issue 5 years ago • 1 comments

The example composer.json has

"autoload": { "psr-4": { "TenUpScaffold\\": "includes/classes/" } }

But then there is no example inside the includes/classes/ folder of how to namespace different classes, nor differet example namespaces in the composer.json file, and have them all autoloaded with psr-4.

Would it be possible to include a simple example of how to include classes under different namespaces like, eg,

TenUpScaffold\ClassOne, TenUpScaffold\AnotherClass, TenUpScaffold\AnotherOne\Helper ?

Would be great to see in the sample class how it is initialized, etc.

Thank you for your scaffold repos!

tamara-m avatar Sep 10 '20 13:09 tamara-m

No objections here, I'll defer to @christianc1 for implementation there though

timwright12 avatar Oct 19 '20 12:10 timwright12