Helper class usage
Here are some observations about Helper usage to retrieve config :
- They seem to be older, maybe it is a (sometimes bad) habit from Magento 1 with its data helpers, which has been kept at the begining of Magento 2.
- They often had the
@api
tag early in the Magento project.
If I am not mistaken, @api tag means that the class is safe to use, as it should not have backward incompatible changes. This might be another reason why they are still here.
- They are often surrounded by additional code logic, which makes their purpose to other things than just "get the config".
- Helpers also look heavier, because they usually extend "AbstractHelper" which is requiring a lot of dependency injections and goes against the composite reuse principle (Composition over inheritance).
Config Model class usage
Here are some observations about Config Model usage to retrieve config :
- It looks like new config classes tend to be Models instead of Helpers, making it look like it is a preferred solution than the Helper.
- A Config Model has its own purpose about retrieving the configuration values from the database (or cache), which makes sense about what a model is supposed to do.
- They generaly come with their own Inteface, mapped in the di.xml file for an abstract implementation, which is a good thing.
- Using this kind of Model also seems lighter, because it favors composition over inheritence, which is a good practice.
Conclusion
With all those observations in mind, I would tend to use Models instead of Helpers.
It looks cleaner, lighter, and seems to follow more coding standards.