Querying by composition
with_component filters entities by what they're made of, and scopes to the entity type for free.
Published posts, newest first.
with_component filters entities by what they're made of, and scopes to the entity type for free.
A user *is* a moderator exactly when the row exists. Presence is the whole meaning.
A component costs nothing until a value differs from its default. No row, no query, no ceremony.
Entities are identity; components carry the state and behaviour. It reads like plain Rails.