HTML::...ponent(3pm)
π HTML::Mason::Component::Subcomponent β the glow-up era π
okay bestie, so this is HTML::Mason::Component::Subcomponent, a page from the User Contributed Perl Documentation corner of the internet. she's a Mason Subcomponent Class and she's literally so important, no cap. π
β¨ NAME β¨
HTML::Mason::Component::Subcomponent β Mason Subcomponent Class, your new fave subclass. π
π¦ DESCRIPTION π¦
okay so first thing: this is a subclass of HTML::Mason::Component. Mason uses it to implement both subcomponents (the ones defined by <%def>) and methods (the ones defined by <%method>). two jobs, one icon. π
A subcomponent/method gets most of its properties from its owner β like, it's not out here building its own whole personality, it's borrowing the vibe from whoever it lives inside. π«Ά
β οΈ okay this part is IMPORTANT, listen up: the link from the subcomponent to its owner is a weak reference (specifically to prevent circular references). so if you grab a subcomponent/method object, you should also grab and hold a reference to its owner. if the owner goes out of scope, the subcomponent/method object will become unusable. like, it's giving ghosted. π so hold onto the owner fr fr, that's the whole survival strategy.
π METHODS π
π is_method
Returns 1 if this is a method (declared by <%method>), 0 if it is a subcomponent (defined by <%def>).
like a little vibe check that tells you which one you're looking at. one or zero, method or subcomponent, iconic binary behaviour. β
πΈ owner
Returns the component object within which this subcomponent or method was defined.
basically "who's your person?" and the answer is the component that defined you. π
and that's the whole page, bestie, you ate it. πβ¨
this was rendered with perl v5.38.2 and dated 2024-03-05, so that's the version and the timestamp β go off, little doc. π¦π
π¦ where this page comes from
- debian trixie: libhtml-mason-perl 1:1.60-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libhtml-mason-perl 1:1.60-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libhtml-mason-perl 1:1.60-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms