reactjs / react-docgen

A CLI and library to extract information from React component files for documentation generation purposes.

Home Page:https://react-docgen.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

With Typescript Omit Union types get lost

bmsuseluda opened this issue · comments

Hello together,

with the following code the union type of name gets lost:

interface FullProps {
  /** The name to greet */
  name: "world" | "hello";
  title: string;
}

type Props = Omit<FullProps, "title">

/**
 * Hello world component
 */
const MyComponent = ({name = 'world'}: Props) => {
  return <div />;
}

I have similar problems with Extract and Pick.

Is it possible to support these typescript function?

Thanks in regards