GraphQ...ullable(3pm)

πŸ“¦
version 0.54 Β· 2 versions
  • 0.54 Β· debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking (latest)
  • 0.53 Β· ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

✨ NAME ✨

GraphQL::Role::Nullable β€” it's a GraphQL object role, bestie πŸ’– that's literally the whole thing, but like, stay with me, the details are cute.


🌸 SYNOPSIS 🌸

ok so first things first, you pull the role in like this:

with qw(GraphQL::Role::Nullable);

orrrr if you're feeling chaotic and wanna do it at runtime instead:

Role::Tiny->apply_roles_to_object($foo, qw(GraphQL::Role::Nullable));

both are valid, pick your fighter 🫢


πŸ¦‹ DESCRIPTION πŸ¦‹

Allows type constraints for nullable objects. yeah that's it. that's the vibe. it lets your types be nullable, no cap. sometimes things just can be null and that's not a flaw, that's range πŸ’…


πŸ’œ METHODS πŸ’œ

🌈 non_null

Returns a wrapped version of the type using GraphQL::Type::NonNull, i.e. that may not be null.

so like, the glow-up move: you take your chill nullable type and you wrap it so it's giving absolutely not, no nulls allowed energy πŸ‘‘ if you want the not-nullable version, this is the method, periodt.


k that's the whole page bestie, short and iconic fr fr 🌟

this one's from the User Contributed Perl Documentation, sitting pretty at perl v5.34.0, dated 2022-03-27 πŸŽ€ catch you in the next man page, mwah πŸ’–βœ¨

πŸ“¦ where this page comes from