- Issue created by @donquixote
- 🇦🇺Australia dpi Perth, Australia
The steps required to achieve this are not far off whats needed for ✨ Dynamic hook ID specific attributes Active , effectively Hux just needs to treat an attribute as representing more than one hook. This would involve:
- Introduce a interface for Hook attr.
I dont think it makes sense for others to extend the existing Hook class as the main entry into attributes is the constructor, and having different constructor signatures extending the original doesnt seem right. - A method on the new interface and existing
\Drupal\hux\Attribute\Hook
, getHooks() - Finalise Hook class
- Update HuxDiscovery use instanceof strategy with getAttributes.
- Update HuxDiscovery to invoke and iterate over the returned hooks.
It'd be good to hear opinions on the design as getting it right is my main blocker for ✨ Dynamic hook ID specific attributes Active
- Introduce a interface for Hook attr.
- Status changed to Closed: won't fix
almost 2 years ago 12:40am 16 June 2023 - 🇦🇺Australia dpi Perth, Australia
Closing in favor of ✨ Dynamic hook ID specific attributes Active .
Theres some good ideas here, lets continue