mirror of
https://github.com/foomo/fender-ts.git
synced 2026-08-16 23:10:21 +00:00
17 lines
304 B
TypeScript
17 lines
304 B
TypeScript
import { string } from 'superstruct';
|
|
import { fend, min, optional } from '../../../src';
|
|
|
|
export const Struct = fend(string(), optional, min(10));
|
|
|
|
export const data = 'foobar';
|
|
|
|
export const failures = [
|
|
{
|
|
value: 'foobar',
|
|
type: 'string',
|
|
refinement: 'min',
|
|
path: [],
|
|
branch: [data],
|
|
},
|
|
];
|