Skip to content

expected

expected(msg: string): [LocalError]

Creates an error describing what outcome was expected. This error's type will be ErrorType.Expected.

This is returned as a single-element ErrorList. For a larger list, use merge to join lists.

Parameters

  • msg: The error message describing what was expected.

Returns

  • Returns a single-element array with one error in it.

See Also