import { FunctionComponent } from 'react' import { ParsedUrlQuery } from 'querystring' const FileListing: FunctionComponent<{ query: ParsedUrlQuery }> = ({ query }) => { const { path } = query // Multiple levels of path if (Array.isArray(path)) { return ( <> {path.map((p: any, i: number) => (