import React from 'react';
import { Redirect } from 'react-router-dom';
import type { RedirectProps } from 'react-router-dom';

// This wrapper bypasses the TS2786 error by using 'any' for props
const RedirectWrapper = (props: RedirectProps) => {
    // eslint-disable-next-line
    // @ts-ignore
    // eslint-disable-next-line @typescript-eslint/no-explicit-any
    return <Redirect {...(props as any)} />;
};

export default RedirectWrapper;
