`types` are not exported by default from `utils` folder

I have a few types in a validation file inside the
utils
folder. The schemas that I exported are auto-imported but the types are not. How do i declare types globally?

here is a snapshot of the
validation.ts
file:

import { object, string, number, date, boolean, InferType } from "yup";

export const PaymentSchema = object({
  paymentMethod: string().oneOf(["Direct Payment", "Bank Transfer"]).required("Select a method"),
  transactionId: string().min(3).required("Enter the receipt ID"),
});
// This is not auto-imported in any file
export type TPayment = InferType<typeof PaymentSchema>;


Thanks for the help.
Was this page helpful?