Building a Type Guard for S.Literal Schema

How do I build a type guard? Let's say I have a schema like this:

S.Literal("a", "b", "c");

I want to check a variable x to see if it is valid or not.
Was this page helpful?