Problem/Motivation

The .module file store procedural code that we should store as OOP.

Proposed resolution

Use class resolver to reach properly defined classes.
See an example here : https://git.drupalcode.org/project/entity_visibility_preview/-/blob/8.x-...

Remaining tasks

Implementation.

User interface changes

None

API changes

None

Data model changes

None

Comments

nicoloye created an issue.