Parent issue
#2024083: [META] Clean up and simplify ModuleHandler to improve DX and maintainability
Problem/Motivation
The DX of ModuleHandler or any other place that reads or works with module/theme/profile data is horrible. We need some kind of container through which we can easily access information about extensions, namely themes, modules and possibly profiles too.
Proposed resolution
Introduce classed objects for modules, themes and profiles to increase DX and maintainability of our code. We should be able to create a shared ExtensionInterface which would expect basic methods like ->getVersion(), ->getDescription(), etc.
I believe that this would make module/theme-related code much more readable and less error prone. Also, we would get autocompletion in our IDEs for reading the relevant .info.yml properties.
Detailed concept TBD.