Mo::Inline(3)

πŸ“¦
version 0.40 Β· 2 versions
, in fedora 43

πŸ’– Mo::Inline πŸ’–

okay bestie so this is the manual page for Mo::Inline, from the User Contributed Perl Documentation β€” the ✨glow-up✨ guide to yeeting your Mo dependency straight into your own code. no cap, it's literally the cutest thing. let's go πŸ¦‹


✨ SYNOPSIS ✨

so like, first up β€” in your Mo module:

# This is effectively your own private Mo(ose) setup
package MyModule::Mo;
# use Mo qw'build builder default import';
1;

then from the command line:

> mo-inline lib/MyModule/Mo.pm

or:

> mo-inline lib/

or (if you are really lazy 🫠):

> mo-inline

and then, from another module:

package MyModule::Foo;
use MyModule::Mo;       # gets build, builder and default automatically

like. it just works. slay. πŸ’…


🌸 DESCRIPTION 🌸

so here's the tea β˜• β€” Mo is so small that you can easily inline it, along with any feature modules. Mo literally ships a script called mo-inline that will do it for you. it's giving personal assistant energy, honestly.

all you need to do is comment out the line that uses Mo, and run mo-inline on the file. mo-inline will find such comments and do the inlining for you. and it will also replace any old inlined Mo with the latest version. so it's not just a one-time thing, it's a whole maintenance vibe. πŸ”₯

What Mo could you possibly want? 😭 (yes that's literally the original flex and we're keeping it, iconic)

πŸ‘‘ AUTOMATIC FEATURES πŸ‘‘

by using the Mo::import feature, all uses of your Mo class will turn on all the features you specified. you can override it if you want, bestie β€” but that will be the default. so like, just know what you're signing up for. πŸŽ€


🌈 REAL WORLD EXAMPLES 🌈

for real world examples of Mo inlined using mo-inline, go look at YAML::Mo, Pegex::Mo and TestML::Mo. actual receipts, not just my word for it. ⭐


and that's the whole page, bestie 🫢 β€” this was perl v5.42.0, dated 2025-07-25. go inline something cute. bye!! πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from