io-ts
Version:
TypeScript runtime type system for IO decoding/encoding
15 lines (14 loc) • 431 B
JavaScript
import { memoize } from './Schemable';
// -------------------------------------------------------------------------------------
// constructors
// -------------------------------------------------------------------------------------
/**
* @category constructors
* @since 2.2.0
*/
export function make(schema) {
return memoize(schema);
}
export function interpreter(S) {
return function (schema) { return schema(S); };
}