prisma-zod-generator
Version:
Prisma 2+ generator to emit Zod schemas from your Prisma schema
24 lines (23 loc) • 916 B
TypeScript
/**
* Standardized error handling utilities for PZG Pro
*/
export declare class PZGProError extends Error {
readonly code: string;
readonly feature: string;
readonly context?: Record<string, unknown> | undefined;
constructor(message: string, code: string, feature: string, context?: Record<string, unknown> | undefined);
}
export declare class LicenseError extends PZGProError {
constructor(message: string, context?: Record<string, unknown>);
}
export declare class FileSystemError extends PZGProError {
constructor(message: string, feature: string, context?: Record<string, unknown>);
}
/**
* Safe file operation wrapper
*/
export declare function safeFileOperation<T>(operation: () => Promise<T> | T, filePath: string, feature: string): Promise<T>;
/**
* Production-safe logger that doesn't expose sensitive information
*/
export declare function logError(error: PZGProError): void;