I want to create a custom type in Dart like I would do in typescript. This type should be a subtype of String, accepting only some values.
For example, in Typescript I would do:
type myType = 'HELLO' | 'WORLD' | '!'
How can I do the same stuff in Dart?