Custom logger
Send Zod Config's warnings to your own logger.
Zod Config logs a warning when an adapter fails. By default it uses console. Pass a logger to send these messages somewhere else:
import { } from 'zod';
import { , type } from 'zod-config';
const = .({
: .().(/^\d+$/),
: .(),
});
const : = {
: () => {
// your custom implementation, e.g., log to a file or call an external service
},
};
const = await ({
: ,
: ,
});To turn the warnings off instead, use silent mode.