API reference@evolu/commonType › createBaseTypeErrorFormatter

function createBaseTypeErrorFormatter<Error>(): TypeErrorFormatter<Error>;

Defined in: packages/common/src/Type.ts:730

Creates a formatter function for a base TypeError.

This formatter is specifically for Base Types that only need a simple error message indicating that the value is not of the expected type.

Example

export const formatStringError = createBaseTypeErrorFormatter<StringError>();