fhirbuilder
Version:
Another FHIR Tool to build FHIR Resources
11 lines (10 loc) • 607 B
TypeScript
import * as resources from '../resources';
import { IOperationOutcome, IOperationOutcomeIssue } from 'fhirtypes/dist/r4';
type RemoveValidatorSuffix<T extends string> = T extends `${infer U}Validator` ? U : T;
type ValidatorTypes = RemoveValidatorSuffix<keyof typeof resources>;
export declare const InternalResourceValidator: Record<ValidatorTypes, (dataToValidate: any, path: string, errors: IOperationOutcomeIssue[]) => void>;
export declare const ResourcesValidator: Record<`${ValidatorTypes}Validator`, (args: unknown) => {
isValid: boolean;
operationOutcome: IOperationOutcome;
}>;
export {};